YARA · ditekSHen detection
DITEKSHEN_MALWARE_Win_Crylock
Detects CryLock ransomware
- Author
- ditekSHen
- Date
- 2020-11-06
- Modified
- 2024-11-01
- Score / Quality
- 75 / 73
What this rule detects
Detects CryLock ransomware
Associated malware family: Crylock.
Targets: Windows PE.
It defines 25 patterns (24 text, 1 hex, 0 regex).
Summary generated from the rule's metadata and condition.
Rule source
malware-win-crylock.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_Crylock : FILE
{
meta:
= "Detects CryLock ransomware"
= "ditekSHen"
= "296288d8-2fdd-592a-aef9-7d4853885594"
= "2020-11-06"
= "2024-11-01"
= "https://github.com/ditekshen/detection"
= "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/yara/malware.yar#L7151-L7186"
= "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
= "dde35dd2c7e89212c4562f2dcf6a78d06fbb3d31150d49e6c48f758b07f1834f"
= 75
= 73
= "FILE"
strings:
$s1 = "Encrypted by BlackRabbit. (BR-" ascii
$s2 = "{ENCRYPTENDED}" ascii
$s3 = "{ENCRYPTSTART}" ascii
$s4 = "<%UNDECRYPT_DATETIME%>" ascii
$s5 = "<%RESERVE_CONTACT%>" ascii
$s6 = "how_to_decrypt.hta" ascii wide
$s7 = "END ENCRYPT ONLY EXTENATIONS" ascii
$s8 = "END UNENCRYPT EXTENATIONS" ascii
$s9 = "END COMMANDS LIST" ascii
$s10 = "END PROCESSES KILL LIST" ascii
$s11 = "END SERVICES STOP LIST" ascii
$s12 = "END PROCESSES WHITE LIST" ascii
$s13 = "END UNENCRYPT FILES LIST" ascii
$s14 = "END UNENCRYPT FOLDERS LIST" ascii
$s15 = "Encrypted files:" ascii
$s16 = { 65 78 74 65 6e 61 74 69 6f 6e 73 00 ff ff ff ff
06 00 00 00 63 6f 6e 66 69 67 00 00 ff ff ff ff
(0a|0d 0a) 00 00 00 63 6f 6e 66 69 67 2e 74 78
74 00 00 ff ff ff ff 03 00 00 00 68 74 61 }
$p1 = "-exclude" fullword
$p2 = "-makeff" fullword
$p3 = "-full" fullword
$p4 = "-nolocal" fullword
$p5 = "-nolan" fullword
$p6 = "\" -id \"" fullword
$p7 = "\" -wid \"" fullword
$p8 = "\"runas\"" fullword
$p9 = " -f -s -t 00" fullword ascii
condition:
uint16( 0 ) == 0x5a4d and ( 3 of ( $s* ) or 6 of ( $p* ) )
}
Strings (25 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $s1 | text | "Encrypted by BlackRabbit. (BR-" | ascii |
| $s2 | text | "{ENCRYPTENDED}" | ascii |
| $s3 | text | "{ENCRYPTSTART}" | ascii |
| $s4 | text | "<%UNDECRYPT_DATETIME%>" | ascii |
| $s5 | text | "<%RESERVE_CONTACT%>" | ascii |
| $s6 | text | "how_to_decrypt.hta" | ascii wide |
| $s7 | text | "END ENCRYPT ONLY EXTENATIONS" | ascii |
| $s8 | text | "END UNENCRYPT EXTENATIONS" | ascii |
| $s9 | text | "END COMMANDS LIST" | ascii |
| $s10 | text | "END PROCESSES KILL LIST" | ascii |
| $s11 | text | "END SERVICES STOP LIST" | ascii |
| $s12 | text | "END PROCESSES WHITE LIST" | ascii |
| $s13 | text | "END UNENCRYPT FILES LIST" | ascii |
| $s14 | text | "END UNENCRYPT FOLDERS LIST" | ascii |
| $s15 | text | "Encrypted files:" | ascii |
| $s16 | hex | { 65 78 74 65 6e 61 74 69 6f 6e 73 00 ff ff ff ff 06 00 00 00 63 6f 6e 66 69 67 00 00 ff ff ff ff (0a|0d 0a) 00 00 00 63 6f 6e … | |
| $p1 | text | "-exclude" | fullword |
| $p2 | text | "-makeff" | fullword |
| $p3 | text | "-full" | fullword |
| $p4 | text | "-nolocal" | fullword |
| $p5 | text | "-nolan" | fullword |
| $p6 | text | "\" -id \"" | fullword |
| $p7 | text | "\" -wid \"" | fullword |
| $p8 | text | "\"runas\"" | fullword |
| $p9 | text | " -f -s -t 00" | fullword ascii |
Condition
uint16( 0 ) == 0x5a4d and ( 3 of ( $s* ) or 6 of ( $p* ) )In plain words (Heuristic)
- The file must start with “MZ” — a Windows executable (PE).
- At least 3 patterns in ( $s* ) must match.
- At least 6 patterns in ( $p* ) 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.
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).
Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.
Rule id: 296288d8-2fdd-592a-aef9-7d4853885594
Tags:FILE
Related rules
- TELEKOM_SECURITY_Crylock_BinaryMetadata onlyMalwareTelekom Security malware analysis· Thomas Barabosch, Telekom Security· 2021-06-28
- ARKBIRD_SOLG_RAN_Crylock_Oct_2020_1Metadata onlyMalwareArkbird SOLG (DailyIOC)· Arkbird_SOLG· 2020-10-14
- TELEKOM_SECURITY_Crylock_HtaMetadata onlyMalwareTelekom Security malware analysis· Thomas Barabosch, Telekom Security· 2021-06-28
- MalwareditekSHen detection· ditekSHen· 2034-02-17
- MalwareditekSHen detection· ditekSHen· 2020-11-06
- MalwareditekSHen detection· ditekSHen· 2020-11-06
- MalwareditekSHen detection· ditekSHen· 2020-11-06
- MalwareditekSHen detection· ditekSHen· 2020-11-06