Skip to content

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_Hakunamatata_Builder

Detects HakunaMatata ransomware builder

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

What this rule detects

Detects HakunaMatata ransomware builder

Associated malware family: Hakunamatata.

Targets: Windows PE.

It defines 11 patterns (10 text, 0 hex, 1 regex).

Summary generated from the rule's metadata and condition.

Rule source

malware-win-hakunamatata-builder.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_Hakunamatata_Builder : FILE
{
	meta:
		description = "Detects HakunaMatata ransomware builder"
		author = "ditekSHen"
		id = "dbf3490f-418c-5d3b-9f9e-e9fb29d8b652"
		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#L10086-L10104"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "ac258851de38504cf63ba51fd06f8a9a3dfbe0096d199ba702e9763b5ecc43e4"
		score = 75
		quality = 73
		tags = "FILE"

	strings:
		$s1 = "ENCRYPT FILES IN PROCESS" wide
		$s2 = "#TARGET_FILES" ascii wide
		$s3 = "HAKUNA MATATA" ascii wide nocase
		$s4 = "#PRIVATE_KEY" ascii wide
		$s5 = "/target:winexe /platform:anycpu /optimize+" wide
		$s6 = "/win32icon:" fullword wide
		$s7 = "SkippedFolders" ascii
		$s8 = "RECURSIVE_DIRECTORY_LOOK(" ascii
		$s9 = "DRAW_WALLPAPER(" ascii
		$s10 = "startupKey.SetValue(MESSAGE_FILE.Split('.')[0], executablePath);" ascii
		$s11 = /\\obj\\(Debug|Release)\\Hakuna\sMatata\.pdb/ ascii

	condition:
		uint16( 0 ) == 0x5a4d and 5 of them
}

Strings (11 patterns)

IdentifierTypeValueModifiers
$s1text"ENCRYPT FILES IN PROCESS"wide
$s2text"#TARGET_FILES"ascii wide
$s3text"HAKUNA MATATA"ascii wide nocase
$s4text"#PRIVATE_KEY"ascii wide
$s5text"/target:winexe /platform:anycpu /optimize+"wide
$s6text"/win32icon:"fullword wide
$s7text"SkippedFolders"ascii
$s8text"RECURSIVE_DIRECTORY_LOOK("ascii
$s9text"DRAW_WALLPAPER("ascii
$s10text"startupKey.SetValue(MESSAGE_FILE.Split('.')[0], executablePath);"ascii
$s11regex/\\obj\\(Debug|Release)\\Hakuna\sMatata\.pdb/ascii

Condition

uint16( 0 ) == 0x5a4d and 5 of them

In plain words (Heuristic)

  • The file must start with “MZ” — a Windows executable (PE).
  • At least 5 patterns in the rule must match.

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: dbf3490f-418c-5d3b-9f9e-e9fb29d8b652

Tags:FILE