Android

7 Practical Ways to Detect and Prevent Cobalt Strike on Your Network

7 Practical Ways to Detect and Prevent Cobalt Strike on Your Network
In this guide
  1. What Is Cobalt Strike and How Does It Work?
  2. How to Detect Cobalt Strike on Your Network
  3. 1. Keep an Eye on Popular Services
  4. 2. Hidden Code
  5. 3. Monitor Key Network Indicators
  6. 4. Track Network Communications
  7. 5. Control User Agents
  8. 6. Observe the Destination Domain
  9. 7. Check the Host Header and URI
  10. Conclusion

Since its inception, Cobalt Strike has become one of the most popular threat emulation tools used by cybersecurity red teams. Because Cobalt Strike uses multiple sophisticated exploitation techniques, it has also caught the attention of cybercriminals.

Slowly but surely, Cobalt Strike attacks are becoming more common. From targeting military and government installations to letting advanced persistent threat groups move laterally through a network, it is a far more serious threat than most businesses might think.

In this article, you will learn seven effective ways to identify Cobalt Strike and stop it from affecting your network.

What Is Cobalt Strike and How Does It Work?

Cobalt Strike is a penetration testing tool tailor-made to launch targeted cybersecurity attacks. By adding a social engineering element to cyberattacks, it tries to get a foothold in your network. It also runs hidden commands, uses VPN pivoting and takes advantage of team collaboration and reporting capabilities.

It is based on the client-server model: a red team member connects to the team server using a Cobalt Strike client. Since all connections to and from it are managed by the HOSTNOC VPS server, the red team member has complete control. Cobalt Strike is usually used to launch spear-phishing attacks or gain unauthorized access to systems. It can also emulate different types of malware and other advanced threats.

How to Detect Cobalt Strike on Your Network

Here are seven ways to identify Cobalt Strike on your network.

After exploiting a vulnerability, Cobalt Strike usually emulates a frequently used service so it is never detected. Because it uses Malleable C2, it lets cyber attackers modify command and control traffic as they like. Attackers make the C2 traffic look like legitimate traffic from these popular services and applications, so it is much harder to detect.

2. Hidden Code

Most antivirus software uses sandboxing to check executable files. Sandboxing gives the antivirus a separate environment where it can run and test executable files, so a malicious file won’t affect other systems. The problem with Cobalt Strike is that it hides shellcode in a named pipe. If a sandbox cannot emulate named pipes, this malicious shellcode can easily slip through the cracks unnoticed. What’s more, attackers can tweak it and create new techniques of their own with the Cobalt Strike Artifact Kit.

3. Monitor Key Network Indicators

Cobalt Strike can hide its shellcode and mimic popular services, so how can a business identify Cobalt Strike on its network? By analyzing network traffic. Cobalt Strike usually bypasses security solutions by using fake HTTPS traffic to avoid detection. Because of this, you will need to use transport layer security (TLS) inspection. This will help you distinguish bot traffic from legitimate traffic. If that does not work, you can also identify malicious traffic by closely analyzing the data inside HTTPS requests.

4. Track Network Communications

The best way to tell bot traffic from legitimate human traffic is to look at how often a target is contacted. One of the main differences between the two is that bot traffic is uniform and consistent, while legitimate human traffic usually varies over time. Remember that traffic coming from a bot is not always malicious. Dig deeper into the traffic flow and you can easily tell malicious bot traffic from legitimate bot traffic.

5. Control User Agents

Sometimes the origin of bot traffic is not clear. When you analyze the user agents producing TLS traffic, they might look legitimate because they appear to come from web browser user agents. The problem is that hackers can easily create a fake user agent packet flow using sophisticated machine learning algorithms. Whenever your system flags a user agent as “unspecified”, be alert. It is a warning sign and a red flag you cannot afford to ignore.

6. Observe the Destination Domain

VirusTotal tested 93 antivirus engines, and only 7 antivirus engines managed to tag the domain as malicious. This is alarming given the rising number of malicious domains. It clearly shows that businesses should not rely solely on antivirus software to protect them from the latest threats, but should use it alongside other security tools. Even so, we can still detect the domain thanks to vendor reputation models, which can classify it as malicious. This gives you another indicator of compromise, or network artifact, that tells you about a network intrusion.

7. Check the Host Header and URI

When analyzing packet data, dig deeper to see the HTTP host header. You might expect to be taken to a legitimate website but be directed to a malicious one instead. When this happens, it is a clear sign that Cobalt Strike is creating a fake host header. Check the uniform resource identifier (URI) of the flow. You might see a URI that matches a Cobalt Strike Malleable C2 profile. Blocking that URI is not the solution, as it would block all traffic to that domain, including legitimate traffic. Follow these steps in order to protect your network against Cobalt Strike attacks.

Conclusion

The growing number of Cobalt Strike attacks and the variety of their targets make them difficult to track. But if you know where to look, you can identify these attacks early and react to them in time. Closely monitor sensitive network indicators, hidden and malicious code and popular services. Don’t forget to check the host header, the uniform resource identifier and user agents. By keeping a close eye on all these elements, you can detect Cobalt Strike on your network and act quickly to minimize the damage.

How do you protect your network from Cobalt Strike? Let us know in the comments section below.

Written by

Rahul Shakya

Published on TheTechRim in Android.