Security Experts:

Cobalt Strike Bug Exposes Attacker Servers

A recently addressed vulnerability in the Cobalt Strike penetration testing platform could be exploited to identify attacker servers, Fox-IT security researchers reveal.

The bug, which was addressed in January with the release of Cobalt Strike version 3.13, consisted of an uncommon whitespace in server responses and had been leveraged by researchers to identify Cobalt Strike servers for one and a half years.

Designed for adversary simulation, the Cobalt Strike platform is commonly used by penetration testers and red teamers to test a system’s resilience, but has also become the weapon of choice for various threat actors over the past several years.

The platform is commercially and publicly available, and pirated/cracked versions of the software are also being distributed, which contributed to its wide adoption. Some of the actors using it include the financially motivated FIN7 and state-affiliated APT29 groups.

The platform consists of two components, namely an implant (called beacon) and a server (referred to as team server). Written in Java, the server can be used to manage the Cobalt Strike beacons, can act as a webserver for beacons to connect to command and control (C&C), and can also be set to serve the beacon payload, landing pages and arbitrary files.

Communication with the servers, Fox-IT explains, can be fingerprinted via Intrusion Detection System (IDS) signatures and other techniques, thus helping researches draw a better picture of team servers used in the wild.

Analysis of these servers also allowed Fox-IT to discover a bug in the webserver component of the Cobalt Strike team server (which is based on NanoHTTPD, an open source webserver written in Java), which unintendedly returns a surplus whitespace in all its HTTP responses.

This allowed researchers to identify publicly-exposed NanoHTTPD servers, including possible Cobalt Strike team servers.

Using the available data, the researchers were able to “historically identify the state of publicly reachable team servers on the Internet.” Thus, they noticed a steady growth in Cobalt Strike (NanoHTTPD) webservers on ports 80 and 443 as the framework gained popularity over years, but also a decline since early January 2019, when the flaw was addressed.

The security researchers found a total of 7,718 unique Cobalt Strike team servers or NanoHTTPD hosts between January 2015 and February 2019 (the full list is on GitHub), but note that these are used for both legitimate and illegitimate operations, as they cannot be distinguished easily.

The vulnerability was addressed in Cobalt Strike 3.13, but Fox-IT believes it was in the platform for almost 7 years, provided it has been using NanoHTTPD since the first version, released in 2012.

“The fact that the removal of this space is documented in the change log leads us to believe that the Cobalt Strike developers have become aware of the implications of such a space in the server response, and its potential value to blue teams,” Fox-IT says.

Related: PoS Clients Targeted with Cobalt Strike, Card Scraping Malware

Related: Hackers Exploit WinRAR Vulnerability to Deliver Malware

view counter