SystemBC is like Christmas in July for SOCKS5 Malware and Exploit Kits

Share with your network!


SystemBC is a previously undocumented malware that we have recently observed as a payload in both RIG and Fallout exploit kit (EK) campaigns. While EK activity has remained quite low relative to its peak in early 2016, exploit kits remain important vectors for malware distribution, particularly in regions where Windows piracy is common. The new malware utilizes SOCKS5 proxies to mask network traffic to and from Command and Control (C&C) infrastructure using secure HTTP connections for well-known banking Trojans such as Danabot, which we have also observed distributed in the same EK campaigns.

A related sample of this malware may have been identified by other Infosec researchers on Twitter [2] in mid-October of 2018 distributing AZORult instead of Danabot. SystemBC may also have connections to Brushaloader and related malware.

Campaign Analysis

While analyzing a Fallout EK campaign on June 4, 2019, Proofpoint researchers observed the distribution of a previously unseen proxy malware. Most recently, the malvertising-based Fallout exploit kit chain has been used to deliver instances of Maze ransomware (Figure 1).

Figure 1: Malvertising-based Fallout EK chain that previously delivered Maze ransomware

On June 6, 2019, Proofpoint researchers observed the new proxy malware in the wild again [3]. This time it was being delivered via a Fallout EK and PowerEnum campaign (Figure 2) alongside an instance of the Danabot banking Trojan (affiliate ID 4).

Figure 2: Fallout EK dropping PowerEnum, which has been observed instructing the download of Danabot Affid 4 and a proxy malware DLL

Between July 18 and 22, 2019, Proofpoint researchers observed the proxy malware a third time. This time it was being distributed by the Amadey Loader, which itself was being distributed in a RIG EK campaign.

Other security researchers have also observed the malware being used in the wild. Notably, Vitali Kremez saw a sample of the malware on May 2, 2019 [3], and @nao_sec observed it in connection with in a third Fallout EK campaign on July 13, 2019 [4].

Marketplace Analysis

Since this proxy malware was being used in multiple separate campaigns, Proofpoint researchers believe it was very likely that it was being sold in an underground marketplace. Moreover, we found an advertisement from April 2, 2019, on an underground forum that described a malware named “socks5 backconnect system” (Figure 3) that matched the functionality of the malware seen in the above campaigns. To differentiate from other malware leveraging SOCKS5, we dubbed the new malware “SystemBC” based on the URI path shown in the advertisement’s panel screenshots (Figures 4 and 5).

Original forum advertisement for SystemBC

Figure 3: Original forum advertisement for SystemBC (translated from Russian)

The advertisement also contains screenshots of the C&C panel (Figure 4-6). The simple C&C panel boasts a list of victim computers, automated updating, and built-in authentication.  The builder allows users to create a set number of samples with custom configurations.Figure 3: Original forum advertisement for SystemBC malware (translated from Russian)

Figure 4: SystemBC Administrator Panel (as observed in an underground advertisement)

Figure 5: Another section of the SystemBC Administrator Panel (as observed in an underground advertisement)

Figure 6: SystemBC Builder (as observed in the advertisement noted above)

Malware Analysis

SystemBC is written in C++ and primarily sets up SOCKS5 proxies on victim computers that can then be used by threat actors to tunnel/hide the malicious traffic associated with other malware.


Important strings such as the C&C servers, DNS servers, and port number are encrypted with a 40-byte XOR key that is stored in memory. Reference [5] is a GitHub-hosted Ghidra Python script that can be used to decrypt the configuration from the analyzed sample (Figure 7):

Figure 7: Decrypted malware configuration

The DNS servers are used to resolve “.bit” domains.  The malware calls a function to check whether the server name ends in “.bit.”  If it does, a DNS query will be generated by iterating through the list of DNS hostnames until the malware finds a valid server  (Figures 8 and 9). It is worth mentioning that although both the screenshots and samples reference OpenNIC, they are no longer resolving “.bit” domains [6].

Figure 8: SystemBC performing the initial “.bit” check

Malware checks to see if last four characters of server name are '.bit'

Figure 9: The malware checks to see if the last four characters of the server name are “.bit”

Command and Control

All packets are encrypted using standard RC4, but the S-Box is initialized in a novel way (Figure 10):

Figure 10: Side-by-side comparison of the SystemBC RC4 S-Box initialization (left) and the more common implementation (right)

An example of the hex-encoded (for visibility) C&C communications are available in Figure 11:

Figure 11: Example C&C communications (hex-encoded for visibility)

The client begins the communication by sending a 100-byte packet to the C&C address.

The packet contains four elements:

Bytes 0-49

Plaintext RC4 key

Bytes 50-51

Windows build ID

Bytes 52-53

Boolean determining if the client is running on an x64 processor

Bytes 53-99

Client machine’s account name, with trailing zeroes

It was derived from the following decompiled code (Figure 12):

Figure 12: Logic of initial packet creation

This is verified by decrypting the last 50 bytes of the packet using the first 50 bytes as the RC4 key.  The result is plaintext data (Figure 13).

Figure 13: Decryption of the initial packet data

The return packet from the C&C server contains two main segments, a header and data, which are decrypted separately using the RC4 key from the first packet.  The header, which makes up the initial 4 bytes of the packet, has a type, index, and length field.  The data segment takes up the remaining bytes in the packet and contains details for the creation of a SOCKS5 proxy connection.  A breakdown of the packet is as follows:

Byte 0



 1: Indicates the following “data” packet is SOCKS5 proxy traffic and is associated with the identified index number.

 0: Create a new proxy and will assign it the given index number. The index number is assigned by the C&C server and is used to associate traffic to a particular proxy.

-1: Update malware by downloading an executable, save it with a randomly generated name in the TEMP directory, then run the file

Byte 1

Index: Tells the infected machine which proxy to use

Bytes 2-3

Length: records the number of bytes in the following data chunk

Bytes 3-

SOCKS5 packet information


Figure 14: Decryption of the first response packet

Referencing source [7], we can map these values to a structured SOCKS5 client connection request packet to yield (for example):

Version: 5

Command code: 1

Reserved: 0

Address type: 3

Length of domain: 19

Domain name:

Port number: 443

The second packet sent from the client to the server contains a 3-byte RC4-encrypted header consisting of an index number and data length.  Repeating the above steps, but instead assuming a 3-byte header, we can decrypt a typical SOCKS5 server acknowledgment:

Version: 5

Status: 0

Reserved: 0

Address type: 1

IPv4 Address: 00 00 00 00

Port number: 00 00

This sample goes on to initialize another proxy with a different domain name and an incrementing index value.

With the proxies initialized, the client now begins to retrieve data requested from the C&C via HTTPS.  We can discern that data with a 3-byte header contains response data sent from the proxy while data sent with a 4-byte header are commands from the C&C server.


Proofpoint researchers have identified a previously undocumented proxy malware, dubbed  "SystemBC", being distributed by the Fallout and RIG exploit kits.

In the most recently tracked example, the Fallout exploit is used to download the Danabot banking Trojan and a SOCKS5 proxy which is used on the victim’s Windows system to evade detection of command and control (C&C) traffic. The synergy between SystemBC as a malicious proxy and mainstream malware creates new challenges for defenders relying on network edge detections to intercept and mitigate threats like banking Trojans.

Proofpoint recommends that organizations continue to remain vigilant in keeping their Windows client and server operating systems as well as infrastructure devices patched with vendor-recommended updates and patches, to retire the use of legacy systems which use susceptible browser plugins such as Adobe Flash Player, and to retire legacy Windows systems that may be susceptible to exploit kits such as Fallout. 











Indicators of Compromise (IOCs)


IOC Type




June 4, 2019 SystemBC Malware



June 4, 2019 SystemBC C&C



June 6, 2019 SystemBC Malware



June 6, 2019 SystemBC C&C



July 18, 2019 Amadey





July 18, 2019 Amadey C2 hosted behind Sandiflux




July 18-22, 2019

Amadey Tasks (SystemBC)



July 18, 2019 SystemBC Malware



July 22, 2019 SystemBC Malware



July 18-22, 2019 SystemBC C&C



July 24, 2019 SystemBC Malware

Subscribe to the Proofpoint Blog