Malicious Office (OLE) — malware analysis report

Static analysis result for SHA-256 16a60c75ba9c517a…

MALICIOUS

Office (OLE)

344.5 KB Created: 2015-06-08 14:19:00 Authoring application: Microsoft Office Word First seen: 2020-02-04
MD5: f8015cb98e492c965d61feb229c57b5f SHA-1: 6fc7a7513b01184cdfeea80c46d8a2f1717f4d6e SHA-256: 16a60c75ba9c517a94586c4a479c47a1911b9ac8e2e8845060c86b553a910bb5
202 Risk Score

Malware Insights

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

The sample contains VBA macros, including AutoOpen and Auto_Close, which are indicative of malicious intent. The `CreateObject` call and `XMLHTTP` execution within the VBA code suggest that the macro is designed to download and execute a secondary payload from a remote source. The document body, while appearing benign, is likely a lure to encourage the user to open the malicious document.

Heuristics 7

  • VBA macros detected medium 4 related findings OLE_VBA_MACROS
    Document contains VBA macro code
  • AutoOpen macro high OLE_VBA_AUTOOPEN
    AutoOpen macro
  • Auto_Close macro high OLE_VBA_AUTOCLOSE
    Auto_Close macro
  • CreateObject call high OLE_VBA_CREATEOBJ
    CreateObject call
  • 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.
  • 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://ns.adobe.com/xap/1.0/ In document text (OLE body)
    • http://www.w3.org/1999/02/22-rdf-syntax-ns#In document text (OLE body)
    • http://ns.adobe.com/iX/1.0/In document text (OLE body)
    • http://ns.adobe.com/exif/1.0/In document text (OLE body)
    • http://ns.adobe.com/illustrator/1.0/In document text (OLE body)
    • http://ns.adobe.com/pdf/1.3/In document text (OLE body)
    • http://ns.adobe.com/photoshop/1.0/In document text (OLE body)
    • http://ns.adobe.com/tiff/1.0/In document text (OLE body)
    • http://ns.adobe.com/xap/1.0/g/img/In document text (OLE body)
    • http://ns.adobe.com/xap/1.0/sType/ResourceEvent#In document text (OLE body)
    • http://ns.adobe.com/xap/1.0/sType/ManifestItem#In document text (OLE body)
    • http://ns.adobe.com/xap/1.0/sType/ResourceRef#In document text (OLE body)
    • http://ns.adobe.com/xap/1.0/mm/In document text (OLE body)
    • http://purl.org/dc/elements/1.1/In document text (OLE body)
    • http://schemas.openxmlformats.org/drawingml/2006/mainIn 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) 22755 bytes
SHA-256: fbf0ba18434037edaade6fa56e8c479d86cca7e119a110b437068921dbf6fcbf
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 = "NewMacros"
Option Explicit

Dim ConnStr As String, Sql As String, Gecici As String
Dim EskiKilit, TempTableId, TempTableName, ixReturn, TempGUserId, TempGUserEmailAdres, TempGUserDisplayName, TempAUserEMailAdres, EvrakNo, Dongu, DonguEksiltme
Dim GenelEvrakNo, SubeEvrakNo


Sub AcikOlanDokumanlar(Durum)
    Gecici = GetVariable(ActiveDocument, "Input_URLK") & "?DocId=" & GetVariable(ActiveDocument, "DocId") & _
        "&Durum=" & Durum

    Dim objXMLHTTP, xml
    Set xml = CreateObject("Microsoft.XMLHTTP")
    xml.Open "GET", Gecici, False
    xml.Send
    Set xml = Nothing
End Sub



Sub KagidaBasIlkSMDahil()
    DonguEksiltme = 0
    KagidaBasIlk
End Sub

Sub KagidaBasIlkSMHaric()
    DonguEksiltme = 1
    KagidaBasIlk
End Sub


Sub KagidaBasSonSMDahil()
    DonguEksiltme = 0
    KagidaBasSon
End Sub

Sub KagidaBasSonSMHaric()
    DonguEksiltme = 1
    KagidaBasSon
End Sub


Sub KagidaBasIlk()
    'Dim SayfaSayisi
    SetVariable ActiveDocument, "EskiKilit", GetVariable(ActiveDocument, "AcKapa")
    SetVariable ActiveDocument, "AcKapa", "2"
    Kilit

    ParafZeminOlustur
    
    Application.PrintOut FileName:="", Range:=wdPrintRangeOfPages, Item:= _
        wdPrintDocumentContent, Copies:=1, Pages:="1", PageType:=wdPrintAllPages, _
        ManualDuplexPrint:=False, Collate:=True, Background:=False, PrintToFile _
        :=False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
        PrintZoomPaperHeight:=0
    
    On Error Resume Next
    ParafZeminKaldir
    
    YazdirildiOlarakIsaretle
    
    SetVariable ActiveDocument, "AcKapa", GetVariable(ActiveDocument, "EskiKilit")
    Kilit
    
    On Error GoTo 0
End Sub


Sub KagidaBasSon()
    SetVariable ActiveDocument, "EskiKilit", GetVariable(ActiveDocument, "AcKapa")
    SetVariable ActiveDocument, "AcKapa", "2"
    Kilit

    Dim SayfaSayisi As String
    
    ActiveDocument.Repaginate
    
    SayfaSayisi = ActiveDocument.BuiltInDocumentProperties(wdPropertyPages)

    ParafZeminOlusturSonSayfa
    
    Application.PrintOut FileName:="", Range:=wdPrintRangeOfPages, Item:= _
        wdPrintDocumentContent, Copies:=1, Pages:=SayfaSayisi, PageType:=wdPrintAllPages, _
        ManualDuplexPrint:=False, Collate:=True, Background:=False, PrintToFile _
        :=False, PrintZoomColumn:=0, PrintZoomRow:=0, PrintZoomPaperWidth:=0, _
        PrintZoomPaperHeight:=0
    
    On Error Resume Next
    ParafZeminKaldir
    
    YazdirildiOlarakIsaretle
    
    SetVariable ActiveDocument, "AcKapa", GetVariable(ActiveDocument, "EskiKilit")
    Kilit
    
    On Error GoTo 0
End Sub


Sub YazdirildiOlarakIsaretle()
    Dim ConnEvrak, RsEvrak
    Set ConnEvrak = CreateObject("ADODB.Connection")
    Set RsEvrak = CreateObject("ADODB.RecordSet")
    RsEvrak.CursorLocation = 3
    RsEvrak.CursorType = 3
    RsEvrak.LockType = 3
    ConnEvrak.Open ConnStr

    Sql = "SELECT TOP 1 Ic_Gonderi.TempId " & _
        " FROM Ic_Gonderi " & _
        " WHERE Ic_Gonderi.DocId='" & GetVariable(ActiveDocument, "DocId") & "' "
    RsEvrak.Open Sql, ConnEvrak, 3, 4

    TempTableId = RsEvrak("TempId")

    RsEvrak.Close

    Sql = "SELECT TempTable " & _
        " FROM Template " & _
        " WHERE TempId = " & TempTableId & " "
    RsEvrak.Open Sql, ConnEvrak, 3, 4

    TempTableName = RsEvrak("TempTable")

    RsEvrak.Close
    
    Sql = "UPDATE " & TempTableName & " SET " & TempTableName & ".YazdirmaF = 1 " & _
        " WHERE DocId='" & GetVariable(ActiveDocument, "DocId") & "' "
    RsEvrak.Open Sql, ConnEvrak, 3, 4

End Sub

Function OnaylayanlarinListesi()
    Dim ConnEvrak, RsEvrak
    Set ConnEvrak = CreateObject("ADODB.Connection")
... (truncated)