Zum Inhalt springen

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_PYSA

Detects PYSA/Mespinoza ransomware

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

Was diese Regel erkennt

Detects PYSA/Mespinoza ransomware

Zugehörige Malware-Familie: PYSA.

Ziele: Windows-PE.

Sie definiert 8 Muster (5 Text, 3 Hex, 0 Regex).

Zusammenfassung aus den Metadaten und der Bedingung der Regel erzeugt.

Regelquelltext

malware-win-pysa.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_PYSA : FILE
{
	meta:
		description = "Detects PYSA/Mespinoza ransomware"
		author = "ditekSHen"
		id = "3a3fad6a-46bc-51dc-9723-4412034ca442"
		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#L2080-L2100"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "e614b827bd8d065e94852fed01497c785bf90c52c3624aff9939b3f40ecf96a4"
		score = 75
		quality = 75
		tags = "FILE"
		clamav_sig = "MALWARE.Win.Ransomware.PYSA"

	strings:
		$s1 = "%s\\Readme.README" fullword wide
		$s2 = "Every byte on any types of your devices was encrypted" ascii
		$s3 = { 6c 65 67 61 6c 6e 6f 74 69 63 65 74 65 78 74 00 (50|70) (59|79) (53|73) (41|61) }
		$s4 = { 6c 65 67 61 6c 6e 6f 74 69 63 65 63 61 70 74 69 6f 6e 00 00 (50|70) (59|79) (53|73) (41|61) }
		$s5 = { 2e 62 61 74 00 00 6f 70 65 6e 00 00 00 00 53
                4f 46 54 57 41 52 45 5c 4d 69 63 72 6f 73 6f
                66 74 5c 57 69 6e 64 6f 77 73 5c 43 75 72 72
                65 6e 74 56 65 72 73 69 6f 6e 5c 50 6f 6c 69
                63 69 65 73 5c 53 79 73 74 65 6d 00 00 00 }
		$f1 = ".?AVPK_EncryptorFilter@CryptoPP@@" ascii
		$f2 = ".?AV?$TF_EncryptorImpl@" ascii
		$f3 = "@VTF_EncryptorBase@CryptoPP@@" ascii

	condition:
		uint16( 0 ) == 0x5a4d and all of ( $f* ) and 3 of ( $s* )
}

Strings (8 Muster)

BezeichnerTypWertModifikatoren
$s1Text"%s\\Readme.README"fullword wide
$s2Text"Every byte on any types of your devices was encrypted"ascii
$s3Hex{ 6c 65 67 61 6c 6e 6f 74 69 63 65 74 65 78 74 00 (50|70) (59|79) (53|73) (41|61) }
$s4Hex{ 6c 65 67 61 6c 6e 6f 74 69 63 65 63 61 70 74 69 6f 6e 00 00 (50|70) (59|79) (53|73) (41|61) }
$s5Hex{ 2e 62 61 74 00 00 6f 70 65 6e 00 00 00 00 53 4f 46 54 57 41 52 45 5c 4d 69 63 72 6f 73 6f 66 74 5c 57 69 6e 64 6f 77 73 5c 43 …
$f1Text".?AVPK_EncryptorFilter@CryptoPP@@"ascii
$f2Text".?AV?$TF_EncryptorImpl@"ascii
$f3Text"@VTF_EncryptorBase@CryptoPP@@"ascii

Bedingung

uint16( 0 ) == 0x5a4d and all of ( $f* ) and 3 of ( $s* )

In Worten (Heuristik)

  • Die Datei muss mit „MZ“ beginnen — eine Windows-Programmdatei (PE).
  • Alle Muster aus ( $f* ) müssen treffen.
  • Mindestens 3 Muster aus ( $s* ) 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: 3a3fad6a-46bc-51dc-9723-4412034ca442

Metadaten

clamav_sigMALWARE.Win.Ransomware.PYSA

Tags:FILE