Rustock
- Type
- Rootkit
- Capabilities
- PersistenceDefense evasionProcess injectionReconnaissance
- Platforms
- Windows
Rustock is a Windows kernel-mode rootkit and spam-bot malware family used for financially motivated, large-scale email campaigns, including penny-stock pump-and-dump schemes and rogue online pharmacy advertising. Its botnet was estimated to comprise approximately one million infected computers and generate tens of billions of spam messages daily. Rustock variants were distributed as secondary payloads by malware downloaders, including Pushdo.
Rustock combines driver-based execution, concealed boot-time persistence, and an embedded spam module injected into a legitimate Windows system process. Its rootkit hides startup configuration through registry-function hooking and uses layered encryption and obfuscation to protect its components. An analyzed variant removed executable headers from its decoded rootkit in memory to impede forensic analysis and hooked networking drivers to support the spam module.
Rustock uses RC4-encrypted HTTP POST communications for command and control, with separate key-exchange and instruction phases. It retrieves recipient lists, spam templates, message content, and mail-server discovery information. Host profiling includes operating-system version, bandwidth, SMTP availability, virtual-machine status, and DNS blacklist status. The malware can terminate competing malware, delete associated files, download and execute arbitrary code, and update its spam component.
Rustock's infrastructure suffered disruption when the McColo hosting provider was disconnected in 2008, but operators subsequently restored botnet communications. A Microsoft-led operation in March 2011 seized command-and-control infrastructure and halted its spam operations. The infrastructure takedown did not itself remove Rustock from infected endpoints, which required separate remediation.
Associated threat actors
1 distinct threat actor Mallory has associated with this family across public reporting. Open in Mallory to see the full evidence chain and overlapping campaigns.
Earlier in my Pharma Wars series, I detailed the activities of Cosma — the top SpamIt affiliate who appears to have been responsible for a botnet that competed directly with SPM’s – Rustock.
Techniques & procedures
26 distinct techniques documented for this family, organized by ATT&CK tactic.
Resource Development
6 techniques
Resource Development
No surprise, as it turns out the motive is spam. Using a sandnet, I injected myself into the botnet, able to capture (and blackhole) a small portion of the spam being sent through the system.
Docent: Especially is large volumes ). And from bots. 🙂
This episode tells the stories of some of the worlds biggest spamming botnets. We’ll talk about the botnets Rustock, Waledac, and Cutwail.
2007 A Case Study of the Rustock Rootkit and Spam Bot
The brief resurrection allowed miscreants who rely on McColo to update a portion of the massive botnets they use to push spam and malware... Rustock is capable of sending 30 billion spam messages per day.
the company was shut down by two upstream providers, Global Crossing and Hurricane Electric, because a significant amount of malware and botnets had been trafficking from the McColo servers.
Initial Access
3 techniques
Initial Access
This technique is known as a “drive-by download”; when a user views the infected site, malicious code will be installed to the victim machine without the user’s knowledge or consent.
Google rented his crime machine to members of SpamIt, an organization that paid spammers to promote rogue Internet pharmacy sites... SpamIt members could rent access to the collection of hacked machines via... 'Reactor Mailer.'
McColo customers were responsible for a substantial proportion of all email spam then flowing and subsequent reports claim a two-thirds or greater reduction in global spam volume.
Execution
1 technique
Execution
criminals typically control large botnets, collections of sometimes tens of thousands of computers infected by backdoor Trojans.
Persistence
1 technique
Persistence
The registry key HKLM\system\CurrentControlSet\services\pe386 used to start the malware disappears from the registry as soon as the malware is loaded... the rootkit component entry function... [uses] the registry path pointing to the registry key that loaded the malware driver file into the operating system.
Privilege Escalation
2 techniques
Privilege Escalation
This notify routine creates at most two threads to inject the spam component into the services.exe process... It was previously mentioned that the spam module is injected into the services.exe process, this is another step taken by the malware to thwart detection.
The registry key HKLM\system\CurrentControlSet\services\pe386 used to start the malware disappears from the registry as soon as the malware is loaded... the rootkit component entry function... [uses] the registry path pointing to the registry key that loaded the malware driver file into the operating system.
Stealth
7 techniques
Stealth
MITRE ATT&CK catalogs the technique as T1014 under defense evasion.
2009 Rootkit Installation and Obfuscation in Rustock
This notify routine creates at most two threads to inject the spam component into the services.exe process... It was previously mentioned that the spam module is injected into the services.exe process, this is another step taken by the malware to thwart detection.
Deletes all sub-keys in the hive: HKLM\system\CurrentControlSet\Enum\Root\Legacy_lzx32.sys
Next, the client sends information about itself to the server including bandwidth, OS version, SMTP availability (if outbound TCP/25 is allowed), if it is a virtual machine...
Deletes all sub-keys in the hive: HKLM\system\CurrentControlSet\Enum\Root\Legacy_lzx32.sys Replaces the registry functions to hide the registry key created to load the malware at boot.
The bootkit then decrypts this packet, and inside there is a DLL file which the bootkit loads to memory and which does not exist as a file on disk!
Discovery
3 techniques
Discovery
Next, the client sends information about itself to the server including bandwidth, OS version, SMTP availability (if outbound TCP/25 is allowed), if it is a virtual machine, and if it is blacklisted on a DNS blacklist.
Next, the client sends information about itself to the server including bandwidth, OS version, SMTP availability (if outbound TCP/25 is allowed), if it is a virtual machine...
And, as with a lot of spam these days, it's the pump-and-dump kind of spam touting penny stocks to would-be investors.
Command and Control
6 techniques
Command and Control
Microsoft crippled Rustock by convincing a court to let it seize dozens of Rustock control servers... the servers only were used to coordinate the activities of hundreds of thousands of PCs infected with Rustock, periodically sending them program updates and new spamming instructions.
Both phases are initiated by the client in the form of HTTP POSTs... The HTTP POST from the client contains a 96-byte encrypted payload and is sent to the login.php page on the server... The instruction phase... consists of a variable number of HTTP POSTs from the client and corresponding responses from the server.
McColo was one of the leading players in the so-called "bulletproof hosting" market — ISPs that will allow servers to remain online regardless of complaints.
the servers only were used to coordinate the activities of hundreds of thousands of PCs infected with Rustock, periodically sending them program updates and new spamming instructions.
McColo briefly returned online so it could hand-off command and control channels to a new source... PCs infected by the Rustock botnet [were] being updated so they'd report to a new server located at abilena.podolsk-mo.ru for instructions.
By looking through a network traffic dump we determine that all C&C communications are encrypted... the encryption algorithm used to encrypt the data was RC4.
Observables
11 indicators attributed across vendor reports, sandbox runs, and researcher write-ups. Values are masked here and available in full in Mallory.
Recent activity
45 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.