Campaign Targets Russian-Speaking Enterprises With New Backdoor

A malicious email campaign that has been active for at least two months is targeting Russian-speaking enterprises and delivering a new Windows-based backdoor, Trend Micro warns.

The attack relies on a variety of exploits and Windows components to run malicious scripts in an attempt to make detection and blocking more challenging. The earliest sample associated with the attack was uploaded to VirusTotal on June 6, 2017 and Trend Micro observed five spam runs from June 23 to July 27, 2017. The campaign is believed to be ongoing.

Targets in this attack included financial institutions (such as banks) and mining firms. Trend Micro’s researchers noticed that the attackers have diversified their tactics by sending different, targeted emails for each run. Because of the emails’ limited distribution and specificity in social engineering lures, they should be considered part of a spear-phishing campaign, Trend Micro says.

The emails look as if they come from sales and billing departments and contain a malformed Rich Text Format (RTF) file that exploits a vulnerability (CVE-2017-0199) in Microsoft Office’s Windows Object Linking and Embedding (OLE) interface that was patched in April (the flaw is still being abused by threat actors such as Cobalt and CopyKittens).

Once the exploit code was executed, it downloads a fake XLS file embedded with malicious JavaScript. When opened, the Excel header is ignored and the file is treated as an HTML Application file by the Windows component mshta.exe.

The JavaScript code calls the odbcconf.exe normal executable, which performs various tasks associated with Microsoft Data Access Components, to run the DLL. Once executed, the DLL drops a file in the %APPDATA% folder and appends the .TXT extension to it, although this is an SCT file (Windows scriptlet) normally used to declare variables, define expressions, and add functional codes in web pages, but packed with malicious, obfuscated JavaScript as part of this attack.

The DLL calls the Regsvr32 (Microsoft Register Server) command-line utility to execute with specific parameters. Called Squiblydoo, this attack method abuses Regsvr32 to bypass restrictions on running scripts and evade application whitelisting protections such as AppLocker, and was previously associated with the activities of Vietnamese hacking group APT32.

“While Squiblydoo is already a known attack vector, this is the first time we’ve seen it combined with odbcconf.exe,” Trend Micro notes.

Next, another XML file is executed, after being downloaded from the domain wecloud[.]biz. This is the main backdoor used in this attack, which is executed using the same Regsvr32-abusing Squiblydoo attack technique.

The backdoor is a SCT file with obfuscated JavaScript code inside and supports commands that “essentially allow attackers to take over an infected system.” The backdoor attempts to connect to the command and control (C&C) server at hxxps://wecloud[.]biz/mail/ajax[.]php and retrieve tasks.

Based on the received commands, the malware can download and execute Portable Executable (PE) files, delete files/startup entries and terminate, download additional/new scripts, run new script and terminate current script, or run command shell commands.

“While the later stages of the infection chain required the use of various Windows components, the entry point still involves the use of a Microsoft Office exploit. Patching and keeping software up-to-date will protect users. Alternately, employing firewalls, intrusion detection and prevention systems, virtual patching, and URL categorization, as well as enforcing robust patch management policies, will significantly reduce the system’s attack surface,” Trend Micro notes.

Related: Cobalt Hackers Now Using Supply Chain Attacks

Related: Iranian ‘CopyKittens’ Conduct Foreign Espionage 

view counter

Ionut Arghire is an international correspondent for SecurityWeek.

Previous Columns by Ionut Arghire:

Tags: