YARA · SEKOIA.IO Community
SEKOIA_Ransomware_Win_Chaos
Detects the Chaos Ransomware
- Author
- Sekoia.io
- Date
- 2022-01-18
- Modified
- 2024-12-19
- Score / Quality
- 75 / 78
What this rule detects
Detects the Chaos Ransomware
Targets: Windows PE.
It defines 28 patterns (28 text, 0 hex, 0 regex).
Summary generated from the rule's metadata and condition.
Rule source
ransomware-win-chaos.yarDetection Rule License 1.1
rule SEKOIA_Ransomware_Win_Chaos : FILE
{
meta:
= "Detects the Chaos Ransomware"
= "Sekoia.io"
= "c1876a18-0618-44e2-8919-b4a041de97e7"
= "2022-01-18"
= "2024-12-19"
= "https://github.com/SEKOIA-IO/Community"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/ransomware_win_chaos.yar#L1-L46"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
= "1947e6de8f74fe7bc52107d4a57e19eacf022121f5decee54a8c90797be844c6"
= 75
= 78
= "FILE"
= "1.0"
= "TLP:CLEAR"
strings:
$rep00 = "\\Desktop" wide
$rep01 = "\\Links" wide
$rep02 = "\\Contacts" wide
$rep03 = "\\Documents" wide
$rep04 = "\\Downloads" wide
$rep05 = "\\Pictures" wide
$rep06 = "\\Music" wide
$rep07 = "\\OneDrive" wide
$rep08 = "\\Saved Games" wide
$rep09 = "\\Favorites" wide
$rep10 = "\\Searches" wide
$rep11 = "\\Videos" wide
$rep12 = "C:\\Users\\" wide
$str0 = "svchost.exe" wide
$str1 = "\\privateKey.chaos" wide
$str2 = "Chaos Ransomware" wide
$str3 = "read_it.txt" wide
$str4 = "<EncryptedKey>" wide
$str5 = "passwordBytes" ascii
$str6 = "lookForDirectories" ascii
$str7 = "Rfc2898DeriveBytes" ascii
$str8 = "ICryptoTransform" ascii
$str9 = "FromBase64String" ascii
$ext0 = ".torrent" wide
$ext1 = ".ibank" wide
$ext2 = ".wallet" wide
$ext3 = ".swift" wide
$ext4 = ".onetoc2" wide
condition:
uint16( 0 ) == 0x5a4d and filesize > 50KB and filesize < 2MB and 6 of ( $str* ) and 10 of ( $rep* ) and 4 of ( $ext* )
}
Strings (28 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $rep00 | text | "\\Desktop" | wide |
| $rep01 | text | "\\Links" | wide |
| $rep02 | text | "\\Contacts" | wide |
| $rep03 | text | "\\Documents" | wide |
| $rep04 | text | "\\Downloads" | wide |
| $rep05 | text | "\\Pictures" | wide |
| $rep06 | text | "\\Music" | wide |
| $rep07 | text | "\\OneDrive" | wide |
| $rep08 | text | "\\Saved Games" | wide |
| $rep09 | text | "\\Favorites" | wide |
| $rep10 | text | "\\Searches" | wide |
| $rep11 | text | "\\Videos" | wide |
| $rep12 | text | "C:\\Users\\" | wide |
| $str0 | text | "svchost.exe" | wide |
| $str1 | text | "\\privateKey.chaos" | wide |
| $str2 | text | "Chaos Ransomware" | wide |
| $str3 | text | "read_it.txt" | wide |
| $str4 | text | "<EncryptedKey>" | wide |
| $str5 | text | "passwordBytes" | ascii |
| $str6 | text | "lookForDirectories" | ascii |
| $str7 | text | "Rfc2898DeriveBytes" | ascii |
| $str8 | text | "ICryptoTransform" | ascii |
| $str9 | text | "FromBase64String" | ascii |
| $ext0 | text | ".torrent" | wide |
| $ext1 | text | ".ibank" | wide |
| $ext2 | text | ".wallet" | wide |
| $ext3 | text | ".swift" | wide |
| $ext4 | text | ".onetoc2" | wide |
Condition
uint16( 0 ) == 0x5a4d and filesize > 50KB and filesize < 2MB and 6 of ( $str* ) and 10 of ( $rep* ) and 4 of ( $ext* )In plain words (Heuristic)
- The file must start with “MZ” — a Windows executable (PE).
- The file must be smaller than 2MB (a cheap guard that skips large files).
- The file must be larger than 50KB.
- At least 6 patterns in ( $str* ) must match.
- At least 10 patterns in ( $rep* ) must match.
- At least 4 patterns in ( $ext* ) 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: Sekoia.io
Source repository: SEKOIA.IO Community @ a438a5901a
Licence: Detection Rule License 1.1 (repository licence)
Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.
Rule id: c1876a18-0618-44e2-8919-b4a041de97e7
Metadata
| version | 1.0 |
|---|---|
| classification | TLP:CLEAR |
Tags:FILE
Related rules
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-07-16
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-08-23
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-04-22
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-07-23
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-10-20
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-03-20
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-03-20
- MalwareSEKOIA.IO Community· Sekoia.io· 2024-03-20