YARA · ditekSHen detection
DITEKSHEN_MALWRE_Win_Darkgate
Detects DarkGate infostealer and coinminer
- Author
- ditekSHen
- Date
- 2020-11-06
- Modified
- 2024-11-01
- Score / Quality
- 75 / 75
What this rule detects
Detects DarkGate infostealer and coinminer
Associated malware family: Coinminer.
Targets: Windows PE.
It defines 17 patterns (15 text, 0 hex, 2 regex).
Summary generated from the rule's metadata and condition.
Rule source
malwre-win-darkgate.yarBSD 2-Clause License
rule DITEKSHEN_MALWRE_Win_Darkgate : FILE
{
meta:
= "Detects DarkGate infostealer and coinminer"
= "ditekSHen"
= "4488e1e6-daac-5832-8326-3151c834daf1"
= "2020-11-06"
= "2024-11-01"
= "https://github.com/ditekshen/detection"
= "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/yara/malware.yar#L10747-L10771"
= "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
= "805a04bbb3915d539e76927393384a2786c25490e8b9fc151d5b12415247578b"
= 75
= 75
= "FILE"
strings:
$x1 = "SYSTEM Elevation: Completed, new DarkGate connection with SYSTEM privileges" ascii
$x2 = "-u 0xDark" ascii
$x3 = "DarkGate" ascii
$x4 = "/c cmdkey /generic:\"127.0.0.2\" /user:\"SafeMode\" /pass:\"darkgatepassword0\"" ascii
$s1 = "c:\\temp\\crash.txt" ascii
$s2 = "/cookiesfile \"" ascii
$s3 = "/c rmdir /s /q \"" ascii
$s4 = "/c xcopy /E /I /Y \"%s\" \"%s\" && exit" ascii
$s5 = "U_MemScan" ascii
$s6 = "U_Google_AD" ascii
$s7 = "untBotUtils" ascii
$s8 = "____padoru____" ascii
$s9 = "u_SysHook" ascii
$s10 = "zLAxuU0kQKf3sWE7ePRO2imyg9GSpVoYC6rhlX48ZHnvjJDBNFtMd1I5acwbqT+=" ascii
$s11 = "C:\\Windows\\System32\\ntdll.dll" fullword ascii
$s12 = /(SYSTEM )?Elevation: (Cannot|I already|AT RAW|FAILURE)/ ascii
$s13 = /Stub: (WARNING:|Configuration updated:|Global Ping Invoked)/ ascii
condition:
( uint16( 0 ) == 0x5a4d and ( ( 3 of ( $x* ) ) or ( 2 of ( $x* ) and 3 of ( $s* ) ) or ( 1 of ( $x* ) and 5 of ( $s* ) ) or ( 6 of ( $s* ) ) ) ) or ( 10 of them )
}
Strings (17 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $x1 | text | "SYSTEM Elevation: Completed, new DarkGate connection with SYSTEM privileges" | ascii |
| $x2 | text | "-u 0xDark" | ascii |
| $x3 | text | "DarkGate" | ascii |
| $x4 | text | "/c cmdkey /generic:\"127.0.0.2\" /user:\"SafeMode\" /pass:\"darkgatepassword0\"" | ascii |
| $s1 | text | "c:\\temp\\crash.txt" | ascii |
| $s2 | text | "/cookiesfile \"" | ascii |
| $s3 | text | "/c rmdir /s /q \"" | ascii |
| $s4 | text | "/c xcopy /E /I /Y \"%s\" \"%s\" && exit" | ascii |
| $s5 | text | "U_MemScan" | ascii |
| $s6 | text | "U_Google_AD" | ascii |
| $s7 | text | "untBotUtils" | ascii |
| $s8 | text | "____padoru____" | ascii |
| $s9 | text | "u_SysHook" | ascii |
| $s10 | text | "zLAxuU0kQKf3sWE7ePRO2imyg9GSpVoYC6rhlX48ZHnvjJDBNFtMd1I5acwbqT+=" | ascii |
| $s11 | text | "C:\\Windows\\System32\\ntdll.dll" | fullword ascii |
| $s12 | regex | /(SYSTEM )?Elevation: (Cannot|I already|AT RAW|FAILURE)/ | ascii |
| $s13 | regex | /Stub: (WARNING:|Configuration updated:|Global Ping Invoked)/ | ascii |
Condition
( uint16( 0 ) == 0x5a4d and ( ( 3 of ( $x* ) ) or ( 2 of ( $x* ) and 3 of ( $s* ) ) or ( 1 of ( $x* ) and 5 of ( $s* ) ) or ( 6 of ( $s* ) ) ) ) or ( 10 of them )In plain words (Heuristic)
- The file must start with “MZ” — a Windows executable (PE).
- At least 3 patterns in ( $x* ) must match.
- At least 2 patterns in ( $x* ) must match.
- At least 3 patterns in ( $s* ) must match.
- At least 1 patterns in ( $x* ) must match.
- At least 5 patterns in ( $s* ) must match.
- At least 6 patterns in ( $s* ) must match.
- At least 10 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.
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: 4488e1e6-daac-5832-8326-3151c834daf1
Tags:FILE
Related rules
- MalwareMalpedia signator rules· Felix Bilstein - yara-signator at cocacoding dot com· 2026-05-04
- MalwareTrellix Advanced Research Center· Trellix ATR· 2021-07-22
- 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
- MalwareditekSHen detection· ditekSHen· 2020-11-06