Zum Inhalt springen

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_Ranumbot

Detects RanumBot / Windigo / GoStealer

MalwareRanumbotditekSHen detectionBSD 2-Clause LicenseKompiliert mit YARA-X
Autor
ditekSHen
Datum
2020-11-06
Geändert
2024-11-01
Score / Qualität
75 / 73

Was diese Regel erkennt

Detects RanumBot / Windigo / GoStealer

Zugehörige Malware-Familie: Ranumbot.

Ziele: Windows-PE.

Sie definiert 24 Muster (23 Text, 0 Hex, 1 Regex).

Zusammenfassung aus den Metadaten und der Bedingung der Regel erzeugt.

Regelquelltext

malware-win-ranumbot.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_Ranumbot : FILE
{
	meta:
		description = "Detects RanumBot / Windigo / GoStealer"
		author = "ditekSHen"
		id = "26a0832e-8a39-5a0e-bd39-710744212c16"
		date = "2020-11-06"
		modified = "2024-11-01"
		reference = "https://github.com/ditekshen/detection"
		source_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/yara/malware.yar#L5397-L5430"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "a9c32445e62d072e4184d25497696ef6225edb176dc7a9743a54194d4ddb4b0c"
		score = 75
		quality = 73
		tags = "FILE"

	strings:
		$f1 = "main.addSchedulerTaskSSH" fullword ascii
		$f2 = "main.attackRouter" fullword ascii
		$f3 = "main.decryptPassword" fullword ascii
		$f4 = "main.handleScanRequest" fullword ascii
		$f5 = "main.scanNetwork" fullword ascii
		$f6 = "main.extractCredentials" fullword ascii
		$s1 = "H_T= H_a= H_g= MB,  W_a= and  h_a= h_g= h_t= max= ptr  siz= tab= top= u_a= u_g=%s/16%s:%d%s:22+0330+0430+0530+0545+0630+0845+10" ascii
		$s2 = "<== as  at  fp= is  lr: of  on  pc= sp: sp=) = ) m=+Inf, n -Inf00%x112212343125: p=ABRTACDTACSTAEDTAESTAKDTAKSTALRMAWSTAhomAtoiCESTChamDashEESTGOGCJulyJuneKILLLEAFLisuMiaoModiNZDTNZSTNewaPIPEQUITSASTSEGVTERMThai" ascii
		$s3 = "W*struct { P *big.Int; Q *big.Int; G *big.Int; Y *big.Int; Rest []uint8 \"ssh:\\\"rest\\\"\" }" ascii
		$s4 = "policy=api,ftp,local,password,policy,read,reboot,sensitive,sniff,ssh,telnet,test,web,winbox,write" ascii
		$s5 = "/Users/alexander/go/src/mikrotik/winbox.go" ascii
		$xf1 = "main.readConfig" fullword ascii
		$xf2 = "main.ensureRunningAsUser" fullword ascii
		$xf3 = "main.configRegPath" fullword ascii
		$xf4 = "main.oldConfigRegPath" fullword ascii
		$uf1 = "main.locateChrome" fullword ascii
		$uf2 = "main.decryptAndUploadProfile" fullword ascii
		$uf3 = "main.decryptCookies" fullword ascii
		$uf4 = "main.extractPasswords" fullword ascii
		$uf5 = "main.getFirefoxProfile" fullword ascii
		$uf6 = "main.postBrowsersData" fullword ascii
		$uf7 = "main.uploadFirefoxProfile" fullword ascii
		$uf8 = "main.zipFirefoxProfile" fullword ascii
		$uf9 = /main\.detect(Browsers|Chrome|Coccoc|Edge|Firefox|InternetExplorer|Opera|Yandex)/ fullword ascii

	condition:
		uint16( 0 ) == 0x5a4d and ( 5 of ( $f* ) or 4 of ( $s* ) or ( 2 of ( $f* ) and 2 of ( $s* ) ) or ( all of ( $xf* ) and 1 of ( $uf* ) ) or 6 of ( $uf* ) )
}

Strings (24 Muster)

BezeichnerTypWertModifikatoren
$f1Text"main.addSchedulerTaskSSH"fullword ascii
$f2Text"main.attackRouter"fullword ascii
$f3Text"main.decryptPassword"fullword ascii
$f4Text"main.handleScanRequest"fullword ascii
$f5Text"main.scanNetwork"fullword ascii
$f6Text"main.extractCredentials"fullword ascii
$s1Text"H_T= H_a= H_g= MB, W_a= and h_a= h_g= h_t= max= ptr siz= tab= top= u_a= u_g=%s/16%s:%d%s:22+0330+0430+0530+0545+0630+0845+10"ascii
$s2Text"<== as at fp= is lr: of on pc= sp: sp=) = ) m=+Inf, n -Inf00%x112212343125: p=ABRTACDTACSTAEDTAESTAKDTAKSTALRMAWSTAhomAtoiCESTChamDashEESTGOGCJulyJuneKILL …ascii
$s3Text"W*struct { P *big.Int; Q *big.Int; G *big.Int; Y *big.Int; Rest []uint8 \"ssh:\\\"rest\\\"\" }"ascii
$s4Text"policy=api,ftp,local,password,policy,read,reboot,sensitive,sniff,ssh,telnet,test,web,winbox,write"ascii
$s5Text"/Users/alexander/go/src/mikrotik/winbox.go"ascii
$xf1Text"main.readConfig"fullword ascii
$xf2Text"main.ensureRunningAsUser"fullword ascii
$xf3Text"main.configRegPath"fullword ascii
$xf4Text"main.oldConfigRegPath"fullword ascii
$uf1Text"main.locateChrome"fullword ascii
$uf2Text"main.decryptAndUploadProfile"fullword ascii
$uf3Text"main.decryptCookies"fullword ascii
$uf4Text"main.extractPasswords"fullword ascii
$uf5Text"main.getFirefoxProfile"fullword ascii
$uf6Text"main.postBrowsersData"fullword ascii
$uf7Text"main.uploadFirefoxProfile"fullword ascii
$uf8Text"main.zipFirefoxProfile"fullword ascii
$uf9Regex/main\.detect(Browsers|Chrome|Coccoc|Edge|Firefox|InternetExplorer|Opera|Yandex)/fullword ascii

Bedingung

uint16( 0 ) == 0x5a4d and ( 5 of ( $f* ) or 4 of ( $s* ) or ( 2 of ( $f* ) and 2 of ( $s* ) ) or ( all of ( $xf* ) and 1 of ( $uf* ) ) or 6 of ( $uf* ) )

In Worten (Heuristik)

  • Die Datei muss mit „MZ“ beginnen — eine Windows-Programmdatei (PE).
  • Alle Muster aus ( $xf* ) müssen treffen.
  • Mindestens 5 Muster aus ( $f* ) müssen treffen.
  • Mindestens 4 Muster aus ( $s* ) müssen treffen.
  • Mindestens 2 Muster aus ( $f* ) müssen treffen.
  • Mindestens 2 Muster aus ( $s* ) müssen treffen.
  • Mindestens 1 Muster aus ( $uf* ) müssen treffen.
  • Mindestens 6 Muster aus ( $uf* ) müssen treffen.

Diese Regel im Browser testen

Legen Sie eine Datei ab, um sie mit dieser Regel und YARA-X als WebAssembly zu scannen. Nichts wird hochgeladen.

Datei hier ablegen oder klicken zum AuswählenLokal mit YARA-X gescannt. Dateien bis 200 MB.

Im Editor öffnen

Referenzen

Lizenz & Namensnennung

Autor: ditekSHen

Quell-Repository: ditekSHen detection @ e76c93dcde

Lizenz: BSD 2-Clause License (Repository-Lizenz)

Copyright-Hinweis: Copyright 2021 by ditekSHen (https://github.com/ditekshen/detection).

Originalregel

Gespiegelt über YARA Forge 20260927, das Regelnamen mit der Quelle präfixiert und normalisierte Meta-Felder ergänzt.

Regel-ID: 26a0832e-8a39-5a0e-bd39-710744212c16

Tags:FILE