Skip to content

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_Agnianestealer

Detects Agniane infostealer

MalwareAgnianestealerditekSHen 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 Agniane infostealer

Associated malware family: Agnianestealer.

Targets: Windows PE.

It defines 17 patterns (16 text, 0 hex, 1 regex).

Summary generated from the rule's metadata and condition.

Rule source

malware-win-agnianestealer.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_Agnianestealer : FILE
{
	meta:
		description = "Detects Agniane infostealer"
		author = "ditekSHen"
		id = "fcbbf748-dc01-579f-a6f8-37e0f3dea35e"
		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#L11088-L11114"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "0031fbe6d76868819cbcfc638433d60a50e8f5cfd14ff25af88ed3dffefd7d62"
		score = 75
		quality = 75
		tags = "FILE"
		snort = "923828001"
		clamav = "ditekSHen.MALWARE.Win.AgnianeStealer"

	strings:
		$x1 = "Agniane.pdb" ascii
		$x2 = "IEnumerable<Agniane.Classes.LogRecord>." ascii
		$x3 = "Agniane Stealer" wide
		$x4 = "cinoshibot" wide
		$x5 = "yqbiguuno2zp5jxsmqbev4rwckvy27bqws5cgm3hiid7xolt65j72kqd.onion" wide
		$s1 = "<Pass encoding=\"base64\">" wide
		$s2 = "Domain Detect: detected {0}" wide
		$s3 = "DOMAINDETECTCOOKIES" ascii
		$s4 = /(Opera|Edge|Chrome|Brave|Vivaldi|Blink|Universal|Gecko|OperaGx|Firefox)Grabber/ fullword ascii
		$u1 = "/antivm.php?id=" wide
		$u2 = "/ferr.php?id=" wide
		$u3 = ".php?ownerid=" wide
		$u4 = "&buildid=" wide
		$u5 = "&username=" wide
		$u6 = "&BSSID=" wide
		$u7 = "&rndtoken=" wide
		$u8 = "&domaindetects=" wide

	condition:
		uint16( 0 ) == 0x5a4d and ( 2 of ( $x* ) or ( 1 of ( $x* ) and ( 2 of ( $s* ) or 3 of ( $u* ) ) ) or ( all of ( $s* ) and 3 of ( $u* ) ) or ( 7 of ( $u* ) ) )
}

Strings (17 patterns)

IdentifierTypeValueModifiers
$x1text"Agniane.pdb"ascii
$x2text"IEnumerable<Agniane.Classes.LogRecord>."ascii
$x3text"Agniane Stealer"wide
$x4text"cinoshibot"wide
$x5text"yqbiguuno2zp5jxsmqbev4rwckvy27bqws5cgm3hiid7xolt65j72kqd.onion"wide
$s1text"<Pass encoding=\"base64\">"wide
$s2text"Domain Detect: detected {0}"wide
$s3text"DOMAINDETECTCOOKIES"ascii
$s4regex/(Opera|Edge|Chrome|Brave|Vivaldi|Blink|Universal|Gecko|OperaGx|Firefox)Grabber/fullword ascii
$u1text"/antivm.php?id="wide
$u2text"/ferr.php?id="wide
$u3text".php?ownerid="wide
$u4text"&buildid="wide
$u5text"&username="wide
$u6text"&BSSID="wide
$u7text"&rndtoken="wide
$u8text"&domaindetects="wide

Condition

uint16( 0 ) == 0x5a4d and ( 2 of ( $x* ) or ( 1 of ( $x* ) and ( 2 of ( $s* ) or 3 of ( $u* ) ) ) or ( all of ( $s* ) and 3 of ( $u* ) ) or ( 7 of ( $u* ) ) )

In plain words (Heuristic)

  • The file must start with “MZ” — a Windows executable (PE).
  • All patterns in ( $s* ) must match.
  • At least 2 patterns in ( $x* ) must match.
  • At least 1 patterns in ( $x* ) must match.
  • At least 2 patterns in ( $s* ) must match.
  • At least 3 patterns in ( $u* ) must match.
  • At least 7 patterns in ( $u* ) 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: fcbbf748-dc01-579f-a6f8-37e0f3dea35e

Metadata

snort923828001
clamavditekSHen.MALWARE.Win.AgnianeStealer

Tags:FILE