Two phishing documents named “Lockheed_Martin_JobOpportunities.docx” and “Salary_Lockheed_Martin_job_opportunities_confidential.doc” detected in this campgain.
The initial entry point for the macro is via the ActiveX Frame1_Layout to automatically execute once ActiveX control is enabled.
First macro starts by loading WMVCORE.DLL, which is a legitimate windows dll for windows media.
Interestingly, to make the macro seem more innocuous, Lazarus uses function names identical to the exported functions of WMVCORE.DLL and variable names thematically related to playback.
Then, the macro uses a check for a document variable before entering its main functionality block.
This variable is set at the end to ensure that subsequent opening of the document does not execute it again.
The second stage payload is shellcode that is embedded as a base64 encoded string array inside the macro that is decoded by using CryptStringToBinaryW.
Other variants have used the UuidFromStringA function to decode the embedded payload and write it to an executable Heap.
The decoded shellcode then overwrites the WMIsAvailableOffline function from WMVCORE.dll by retrieving its address and changing its memory permissions.
The callback to the shellcode is achieved by retrieving the KernelCallbackTable pointer from the PEB structure of the current process via NtQueryInformationProcess, and then patching the _fnDWORD pointer to point to WMIsAvailableOffline.
Whenever winword makes any graphical call, the shellcode executes.
The macro then sets a document variable to ensure that subsequent runs would not execute the shellcode decode and the KernelCllbackTable hijack again.
It also retrieves a decoy document and displays it.
The shellcode mainly sets up a periodic beacon out to https://markettrendingcenter[.]com/member[.]htm by creating a new staging folder C:WMAuthorization , writing a vbs file (WMVxEncd.vbs) to it, and creating a corresponding Scheduled task to run the vbs file every 20 minutes.
shellObj is the Wscript.Shell object that the vbs file uses to execute the beacon command.