Russia-linked Sofacy APT developed a new ‘Go’ variant of Zebrocy tool

Pierluigi Paganini December 19, 2018

Researchers at Palo Alto Networks discovered that the Russian-linked Sofacy APT has written a new version of their Zebrocy backdoor using the Go programming language.

The Sofacy APT group has been active since at least 2007 and it has targeted governments, militaries, and security organizations worldwide. The group was involved also in the string of attacks that targeted 2016 Presidential election.

Experts discovered a new variant of the Zebrocy malware that was written using the Go programming language.

“The Sofacy threat group continues to carry out attacks using their Zebrocy tool. We first wrote about the Zebrocy tool in a blog that discussed Sofacy’s parallel attack campaigns during the first quarter of 2018, and more recently during Sofacy attacks in late October and early November. The developers of Zebrocy have once again created a new version the Trojan using a different programming language, specifically the Go language. ” reads the analysis published by Palo alto Networks.

Researchers analyzed the first-stage malware in April and observed that it was used in numerous attacks in October and November. In November, Palo Alto Networks noticed that the Sofacy APT was using a new Trojan in a new wave of attacks.

Previous variants of the Zebrocy tool were developed using different programming language, including AutoIt, Delphi, VB.NET, C#, and Visual C++.

The first attack observed by the experts that involved the Go variant of Zebrocywas spotted on October 11.

Attackers carried out a spear-phishing attack using messages with an LNK attachment that would run a series of PowerShell scripts to extract a payload.

Experts pointed out that the scripts were coded incorrectly and the payload wasn’t installed or executed. The email was discussing the effects of US sanctions on the Russian economy.

The same the Go variant of Zebrocy was involved in a series of attacks carried out between mid-October through mid-November. 

Researchers noticed that in all the attacks threat actors used decoy documents that have the same author name Joohn.

“The delivery documents used in the October and November waves shared a large number of similarities, which allowed us to cluster the activity together. Most notably, the author name Joohn was used repeatedly in each delivery document.” reads the analysis published by Palo Alto Networks.

“There was a slight deviation in the November grouping, where the three samples we collected still used the Joohn author name for the last modified field but reverted to a default USER/user author name for the creator field.”

Palo Alto Networks identified a total of 9 documents and associated payloads and targets.

Once opened a document, it will leverage the ability of Microsoft Word to retrieve a remote template to then load a malicious macro document.

The Go variant of Zebrocy initially starts collecting info on the compromised system, then sends it to the command and control server.

The data collected by the malware includes a list of running processes, information gathered via the ”systeminfo” command, local disk information, and a screenshot of the desktop. 
The malware connects to the C2 through HTTP POST requests.

The malware also attempts to download and execute a payload from the C2 it. The malware shows additional overlaps in functionality with other  Zebrocy variants:

  • The use of ASCII hexadecimal obfuscation of strings
  • The use of the volume serial number without a hyphen obtained from the VOL command
  • The use of the output from “systeminfo” and “tasklist” in the outbound C2 beacon
  • The use of the string “PrgStart” within the C2 beacon

The Zebrocy variant sends data back to the C2 via HTTP POST requests, if the server responds with a hexadecimal encoded payload, the malware saves it to disk, and creates an auto run registry key to gain persistence. The secondary payload was another Trojan written in the Go language, it was used to download additional tools onto the compromised system.

“The Sofacy group continues to use variants of the Zebrocy payload in its attack campaigns.” Palo Alto Networks concludes.

“It is also apparent that the Sofacy group will use these new variants of Zebrocy across multiple different campaigns, as the Go variant of Zebrocy was delivered via the LNK shortcut and a Dear Joohn delivery document,” 

[adrotate banner=”9″] [adrotate banner=”12″]

Pierluigi Paganini

(SecurityAffairs –APT, Sofact)

[adrotate banner=”5″]

 [adrotate banner=”13″]



you might also like

leave a comment