Saltar al contenido

YARA · ditekSHen detection

DITEKSHEN_MALWRE_Win_Darkgate

Detects DarkGate infostealer and coinminer

MalwareCoinminerditekSHen detectionBSD 2-Clause LicenseCompila con YARA-X
Autor
ditekSHen
Fecha
2020-11-06
Modificada
2024-11-01
Puntuación / Calidad
75 / 75

Qué detecta esta regla

Detects DarkGate infostealer and coinminer

Familia de malware asociada: Coinminer.

Objetivos: PE de Windows.

Define 17 patrones (15 de texto, 0 hex, 2 regex).

Resumen generado a partir de los metadatos y la condición de la regla.

Código de la regla

malwre-win-darkgate.yarBSD 2-Clause License
rule DITEKSHEN_MALWRE_Win_Darkgate : FILE
{
	meta:
		description = "Detects DarkGate infostealer and coinminer"
		author = "ditekSHen"
		id = "4488e1e6-daac-5832-8326-3151c834daf1"
		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#L10747-L10771"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "805a04bbb3915d539e76927393384a2786c25490e8b9fc151d5b12415247578b"
		score = 75
		quality = 75
		tags = "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 )
}

Cadenas (17 patrones)

IdentificadorTipoValorModificadores
$x1texto"SYSTEM Elevation: Completed, new DarkGate connection with SYSTEM privileges"ascii
$x2texto"-u 0xDark"ascii
$x3texto"DarkGate"ascii
$x4texto"/c cmdkey /generic:\"127.0.0.2\" /user:\"SafeMode\" /pass:\"darkgatepassword0\""ascii
$s1texto"c:\\temp\\crash.txt"ascii
$s2texto"/cookiesfile \""ascii
$s3texto"/c rmdir /s /q \""ascii
$s4texto"/c xcopy /E /I /Y \"%s\" \"%s\" && exit"ascii
$s5texto"U_MemScan"ascii
$s6texto"U_Google_AD"ascii
$s7texto"untBotUtils"ascii
$s8texto"____padoru____"ascii
$s9texto"u_SysHook"ascii
$s10texto"zLAxuU0kQKf3sWE7ePRO2imyg9GSpVoYC6rhlX48ZHnvjJDBNFtMd1I5acwbqT+="ascii
$s11texto"C:\\Windows\\System32\\ntdll.dll"fullword ascii
$s12regex/(SYSTEM )?Elevation: (Cannot|I already|AT RAW|FAILURE)/ascii
$s13regex/Stub: (WARNING:|Configuration updated:|Global Ping Invoked)/ascii

Condición

( 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 )

En palabras sencillas (Heurística)

  • El archivo debe empezar por «MZ»: un ejecutable de Windows (PE).
  • Deben coincidir al menos 3 patrones de ( $x* ).
  • Deben coincidir al menos 2 patrones de ( $x* ).
  • Deben coincidir al menos 3 patrones de ( $s* ).
  • Deben coincidir al menos 1 patrones de ( $x* ).
  • Deben coincidir al menos 5 patrones de ( $s* ).
  • Deben coincidir al menos 6 patrones de ( $s* ).
  • Deben coincidir al menos 10 patrones de la regla.

Prueba esta regla en tu navegador

Arrastra un archivo para escanearlo con esta regla usando YARA-X compilado a WebAssembly. No se sube nada.

Arrastra un archivo aquí o haz clic para elegirSe escanea en local con YARA-X. Archivos de hasta 200 MB.

Abrir en el editor

Referencias

Licencia y atribución

Autor: ditekSHen

Repositorio de origen: ditekSHen detection @ e76c93dcde

Licencia: BSD 2-Clause License (licencia del repositorio)

Aviso de copyright: Copyright 2021 by ditekSHen (https://github.com/ditekshen/detection).

Regla original

Obtenida a través de YARA Forge 20260927, que añade a los nombres el prefijo de la fuente y campos meta normalizados.

Id de la regla: 4488e1e6-daac-5832-8326-3151c834daf1

Etiquetas:FILE

Más reglas de Coinminer