Skip to content

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_Rhysida

Detects Rhysida ransomware

MalwareRhysidaditekSHen detectionBSD 2-Clause LicenseCompiles with YARA-X
Author
ditekSHen
Date
2020-11-06
Modified
2024-11-01
Score / Quality
75 / 75

What this rule detects

Detects Rhysida ransomware

Associated malware family: Rhysida.

Targets: Windows PE.

It defines 7 patterns (7 text, 0 hex, 0 regex).

Summary generated from the rule's metadata and condition.

Rule source

malware-win-rhysida.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_Rhysida : FILE
{
	meta:
		description = "Detects Rhysida ransomware"
		author = "ditekSHen"
		id = "a70bdf19-3b56-5dc0-be74-20a2e85099cc"
		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#L10888-L10902"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "fb15f497cdee40b237dfc2aafcde2da95ff2a6f9c162273862ec1a0053269932"
		score = 75
		quality = 75
		tags = "FILE"

	strings:
		$s1 = "cmd.exe /c reg add \"HK" ascii
		$s2 = "rundll32.exe user32.dll,UpdatePerUserSystemParameters" fullword ascii
		$s3 = "C:/Users/Public/bg.jpg" fullword ascii
		$s4 = "CriticalBreachDetected.pdf" fullword ascii
		$s5 = "rhysida" ascii
		$s6 = "cmd.exe /c reg delete \"HKCU\\Cont" ascii
		$s7 = "Rhysida-" ascii

	condition:
		uint16( 0 ) == 0x5a4d and 5 of ( $s* ) or ( 3 of ( $s* ) and #s1 > 5 )
}

Strings (7 patterns)

IdentifierTypeValueModifiers
$s1text"cmd.exe /c reg add \"HK"ascii
$s2text"rundll32.exe user32.dll,UpdatePerUserSystemParameters"fullword ascii
$s3text"C:/Users/Public/bg.jpg"fullword ascii
$s4text"CriticalBreachDetected.pdf"fullword ascii
$s5text"rhysida"ascii
$s6text"cmd.exe /c reg delete \"HKCU\\Cont"ascii
$s7text"Rhysida-"ascii

Condition

uint16( 0 ) == 0x5a4d and 5 of ( $s* ) or ( 3 of ( $s* ) and #s1 > 5 )

In plain words (Heuristic)

  • The file must start with “MZ” — a Windows executable (PE).
  • At least 5 patterns in ( $s* ) must match.
  • At least 3 patterns in ( $s* ) must match.
  • Pattern $s1 must occur > 5 times.

Test this rule in your browser

Drop a file to scan it with this rule using YARA-X compiled to WebAssembly. Nothing is uploaded.

Drop a file here or click to chooseScanned locally with YARA-X. Files up to 200 MB.

Open in editor

References

Licence & attribution

Author: ditekSHen

Source repository: ditekSHen detection @ e76c93dcde

Licence: BSD 2-Clause License (repository licence)

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

Original rule

Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.

Rule id: a70bdf19-3b56-5dc0-be74-20a2e85099cc

Tags:FILE

More Rhysida rules