Hackers use a new technique in malspam attacks to disable Macro security warnings in weaponized docs

Pierluigi Paganini July 09, 2021

Threat actors have devised a new trick to disable macro security warning that leverage non-malicious docs in malspam attacks.

Most of the malspam campaigns leverage weaponized Microsoft Office documents and social engineering techniques to trick recipients into enabling the macros.

Now experts from McAfee Labs warn of a novel technique used by threat actors that are using non-malicious documents to disable security warnings prior to executing macro code on the recipient’s PC.

Hackers downloads and executes malicious DLLs (ZLoader) without any malicious code present in the initial spammed attachment macro.

Zloader has been active at least since 2016, it borrows some functions from the notorious Zeus 2.0.8.9 banking Trojan and was used to spread Zeus-like banking trojan (i.e. Zeus OpenSSL)

The attack chain starts with a spam message using a Microsoft Word document that once opened, downloaded a password-protected Microsoft Excel file from a remote server.

The downloads could start only after the victim has enabled the macros embedded in the Word document.

“After downloading the XLS file, the Word VBA reads the cell contents from XLS and creates a new macro for the same XLS file and writes the cell contents to XLS VBA macros as functions.” read the analysis published by McAfee. “Once the macros are written and ready, the Word document sets the policy in the registry to ‘Disable Excel Macro Warning’ and invokes the malicious macro function from the Excel file. The Excel file now downloads the ZLoader payload. The ZLoader payload is then executed using rundll32.exe.”

Upon downloading the XLS file, the Word VBA reads the content of the cells from XLS and uses it to create a new macro for the same XLS file and writes the cell contents to XLS VBA macros as functions.

Once the macros are completed, the Word document disables the macro security warnings by setting the policy in the registry (HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Excel\Security\AccessVBOM) to Disable Excel Macro Warning and executes the malicious macro function of the Excel file.

Then the Excel file downloads and executes the Zloader payload using rundll32.exe.

malspam

“Malicious documents have been an entry point for most malware families and these attacks have been evolving their infection techniques and obfuscation, not just limiting to direct downloads of payload from VBA, but creating agents dynamically to download payloads,” the researchers conclude. “Usage of such agents in the infection chain is not only limited to Word or Excel, but further threats may use other living off the land tools to download its payloads.”

Follow me on Twitter: @securityaffairs and Facebook

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

Pierluigi Paganini

(SecurityAffairs – hacking, malspam)

[adrotate banner=”5″]

[adrotate banner=”13″]



you might also like

leave a comment