Aller au contenu

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_WSHRAT

Detects WASHRAT

MalwareWSHRATditekSHen detectionBSD 2-Clause LicenseCompile avec YARA-X
Auteur
ditekSHen
Date
2020-11-06
Modifiée
2024-11-01
Score / Qualité
75 / 73

Ce que détecte cette règle

Detects WASHRAT

Famille de malware associée : WSHRAT.

Cibles : PE Windows.

Elle définit 11 motifs (10 texte, 0 hex, 1 regex).

Résumé généré à partir des métadonnées et de la condition de la règle.

Source de la règle

malware-win-wshrat.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_WSHRAT : FILE
{
	meta:
		description = "Detects WASHRAT"
		author = "ditekSHen"
		id = "e7940b7f-51dd-5a32-899b-64310f27bf3e"
		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#L10582-L10600"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "297bfe65815637a464e2a8fc23570c6e79694ffe0467d5898b7c845f1450de95"
		score = 75
		quality = 73
		tags = "FILE"

	strings:
		$x1 = "WSH Rat v" wide
		$x2 = "SOFTWARE\\WSHRat" wide
		$x3 = "WSH Remote" wide nocase
		$x4 = "WSHRAT" wide nocase
		$s1 = "shellobj.regwrite \"HKEY_" ascii nocase
		$s2 = "shellobj.run(\"%comspec% /c" ascii nocase
		$s3 = "objhttpdownload.setrequestheader \"user-agent:\"," ascii nocase
		$s4 = "WScript.CreateObject(\"Shell.Application\").ShellExecute" ascii nocase
		$s5 = "objwmiservice.ExecQuery(\"select" ascii nocase
		$s6 = "httpobj.open(\"post\",\"http" ascii nocase
		$s7 = /(rdp|keylogger|get-pass|uvnc)\|http/ wide

	condition:
		uint16( 0 ) == 0x5a4d and ( 2 of ( $x* ) or ( 1 of ( $x* ) and 1 of ( $s* ) ) or ( 6 of ( $s* ) ) )
}

Chaînes (11 motifs)

IdentifiantTypeValeurModificateurs
$x1texte"WSH Rat v"wide
$x2texte"SOFTWARE\\WSHRat"wide
$x3texte"WSH Remote"wide nocase
$x4texte"WSHRAT"wide nocase
$s1texte"shellobj.regwrite \"HKEY_"ascii nocase
$s2texte"shellobj.run(\"%comspec% /c"ascii nocase
$s3texte"objhttpdownload.setrequestheader \"user-agent:\","ascii nocase
$s4texte"WScript.CreateObject(\"Shell.Application\").ShellExecute"ascii nocase
$s5texte"objwmiservice.ExecQuery(\"select"ascii nocase
$s6texte"httpobj.open(\"post\",\"http"ascii nocase
$s7regex/(rdp|keylogger|get-pass|uvnc)\|http/wide

Condition

uint16( 0 ) == 0x5a4d and ( 2 of ( $x* ) or ( 1 of ( $x* ) and 1 of ( $s* ) ) or ( 6 of ( $s* ) ) )

En clair (Heuristique)

  • Le fichier doit commencer par « MZ » — un exécutable Windows (PE).
  • Au moins 2 motifs de ( $x* ) doivent être trouvés.
  • Au moins 1 motifs de ( $x* ) doivent être trouvés.
  • Au moins 1 motifs de ( $s* ) doivent être trouvés.
  • Au moins 6 motifs de ( $s* ) doivent être trouvés.

Tester cette règle dans votre navigateur

Déposez un fichier pour le scanner avec cette règle grâce à YARA-X compilé en WebAssembly. Rien n’est envoyé.

Déposez un fichier ici ou cliquez pour choisirScanné localement avec YARA-X. Fichiers jusqu’à 200 Mo.

Ouvrir dans l’éditeur

Références

Licence et attribution

Auteur : ditekSHen

Dépôt source : ditekSHen detection @ e76c93dcde

Licence : BSD 2-Clause License (licence du dépôt)

Mention de copyright : Copyright 2021 by ditekSHen (https://github.com/ditekshen/detection).

Règle d’origine

Reprise via YARA Forge 20260927, qui préfixe les noms de règles par la source et ajoute des champs meta normalisés.

Identifiant de règle: e7940b7f-51dd-5a32-899b-64310f27bf3e

Tags:FILE

Plus de règles WSHRAT