Explore our new Cybersecurity Terms Glossary, explained by our experts.
Cybersecurity Terms Glossary
Command and control (C2) is the channel attackers use to send instructions to compromised systems and receive stolen data. Learn how C2 hides and how to detect it.

What Is Command and Control (C2)?
Command and control (C2) is the communication channel attackers use to send instructions to compromised systems and receive data back. Once malware or an implant is running inside your network, it “calls home” to infrastructure the attacker controls, waits for tasks, and returns the results. Without working C2, most intrusions stall, which makes detecting and disrupting it one of the most valuable things a defender can do.
A typical modern implant—often called a beacon or agent—does not keep a connection open. It checks in at intervals, for example every 60 seconds with 20% random jitter, asks whether there are new tasks, executes them, and posts the output on its next check-in. Tasks might include running commands, dumping credentials, taking screenshots, moving laterally, or downloading additional tools (MITRE ATT&CK T1105).
ATT&CK treats C2 as an entire tactic, TA0011, which catalogues the ways attackers hide this traffic:
Early botnets used centralised IRC servers, which were easy to find and take down. Later families moved to HTTP-based control panels and then to peer-to-peer designs, in which infected hosts relay commands to each other with no single point of failure. Targeted intruders favour layered infrastructure: short-lived redirectors in front of a long-lived team server, with separate channels for interactive work and for slow, quiet persistence that survives if the main channel is burned.
Red teams use C2 frameworks to emulate real adversaries. Cobalt Strike is the best-known commercial example and Brute Ratel C4 another, while Sliver, Mythic, Havoc, and Metasploit are open-source alternatives. The same tools are widely abused by criminals using cracked or leaked copies. In 2024 the UK’s National Crime Agency led Operation Morpheus, working with Fortra, the owner of Cobalt Strike, and international partners to disrupt around 600 IP addresses hosting illegitimate Cobalt Strike servers.
Law enforcement has also dismantled the C2 infrastructure of major malware families, including Emotet in January 2021 and Qakbot in August 2023, in each case cutting thousands of infected machines off from their operators.
Encryption hides content, but C2 still leaves patterns that a well-instrumented network can see:
Back these detections with egress filtering, an authenticating web proxy, DNS filtering (such as the NCSC’s Protective DNS service for the UK public sector), and threat intelligence feeds of known C2 infrastructure. Each confirmed C2 domain or address then becomes an indicator of compromise to hunt for across the rest of your estate.
Severing C2 too early can tip off the attacker before you have scoped the intrusion, prompting them to switch to a backup channel or deploy ransomware immediately. Responders therefore usually observe first, identify every implant and channel, then block all of them at once during eradication, ideally alongside credential resets. Good retention of DNS, proxy, and firewall logs is what makes that coordinated cut possible.
If you suspect beaconing in your environment, our Managed Security Services (MDR) provide 24/7 monitoring and threat hunting for exactly these patterns.
A botnet is the network of compromised devices; the C2 server is the infrastructure that sends those devices their instructions. In a centralised botnet, taking down the C2 servers effectively disables the botnet. In peer-to-peer designs, infected machines relay commands to each other, so there may be no single C2 server to remove, which makes disruption much harder.
Firewalls block known-bad addresses and unusual ports, and strict egress rules force traffic through inspection points. But most C2 now uses HTTPS or DNS to ordinary-looking or trusted domains, which a simple port-based firewall allows. Effective defence combines egress filtering with DNS filtering, an authenticating proxy, threat intelligence, and behavioural detection of beaconing on the network and endpoints.
Traffic to Microsoft 365, Google Drive, Slack, or GitHub is normal in most organisations, is encrypted, and is rarely blocked. Hiding commands in messages, files, or API calls on those platforms lets implants blend in with everyday activity and avoid domain reputation checks. Defenders respond by monitoring which processes talk to those services and by watching for unusual tenants or accounts.
Yes, when used for authorised work. Red teams and penetration testers run frameworks such as Cobalt Strike, Sliver, and Mythic under contract and with written permission. Using them to access systems without authorisation is an offence under the Computer Misuse Act 1990, and using cracked commercial tools also breaches licence terms.
You May Be Interested In These
We use a few cookies that are needed to make this website work, and they are always on. We would also like to set analytics cookies, to see which pages are useful; functional cookies, so that our live chat works; and advertising cookies, to measure our campaigns. We will not set any of those until you say yes, and you can change your mind at any time from the Cookie Settings link in the footer.
Choose the cookies you are happy for us to use. Strictly necessary cookies are always on; everything else is off until you turn it on.
These cookies keep the website working: they hold your security checks, your form submissions and the choice you make here. The site cannot run without them, so they are always on.
These let our live chat open and remember your conversation, and let the newsletter sign-up work. Switch them off and the chat window will not appear.
These tell us which pages are read and how people find us, so that we can improve the site. The reports are about groups of visitors, never about you personally.
These let us measure our advertising and show you our adverts on other websites, such as LinkedIn, Google and Meta. Switch them off and you will still see adverts, but they will be less relevant.