Saltar al contenido
Nuevo

DeepSeek V4.1 Flash gratis por 7 días: 10M tokens al día tras una recarga de $10 o más. Hasta el 30/11.

Cómo funciona
mukul975/hunting-for-anomalous-powershell-executionDFIR y threat hunting

hunting-for-anomalous-powershell-execution

⁨Hunt for malicious PowerShell activity by analyzing Script Block Logging⁩

v1.03 instalaciones+3 en 7 días36,3 mil EstrellasApache-2.0sincronizado hace 12 horas

Instalar

¿Aún no tienes la CLI de NotHoly? Instálala primero.

$ curl -fsSL https://notholy.com/install.sh | sh
$ notholy skills install mukul975/hunting-for-anomalous-powershell-execution

Escribe en ⁦~/.notholy/skills⁩ después de comprobar la firma y el SHA-256.

FirmaFirmado, ed25519
wcM7M8t+my…3smyI5AA==La CLI comprueba el SHA-256 y la firma antes de escribir cualquier archivo.
Paquetef7b57ee9…9347c8a0
f7b57ee96d70…cb469347c8a04 archivos · ⁦9.2 KB⁩
EscaneoMedio8 hallazgos
  • command.pipe_to_shellreferences/api-reference.md:54
  • command.pipe_to_shellreferences/api-reference.md:61
  • command.base64_execreferences/api-reference.md:62
Ver el escaneo completo
Fuentegithub.com/mukul975/Anthropic-Cybersecurity-Skills/tree/main/skills/hunting-for-anomalous-powershell-execution@54a7988

Esta entrada todavía no está escrita en tu idioma, así que aparece en English.

Overview

PowerShell Script Block Logging (Event ID 4104) records the full deobfuscated script text executed on a Windows endpoint, making it the primary data source for hunting malicious PowerShell. Combined with Module Logging (4103) and process creation events, analysts can detect encoded commands, AMSI bypass patterns, download cradles, credential theft tools, and fileless attack techniques even when the attacker uses obfuscation layers.

When to Use

  • When investigating security incidents that require hunting for anomalous powershell execution
  • When building detection rules or threat hunting queries for this domain
  • When SOC analysts need structured procedures for this analysis type
  • When validating security monitoring coverage for related attack techniques

Prerequisites

  • Windows Event Log exports (.evtx) from Microsoft-Windows-PowerShell/Operational
  • Python 3.8+ with python-evtx and lxml libraries
  • Script Block Logging enabled via Group Policy
  • Understanding of common PowerShell attack techniques

Steps

  1. Parse EVTX files extracting Event 4104 script block text and metadata
  2. Reassemble multi-part script blocks using ScriptBlock ID correlation
  3. Scan script text for AMSI bypass indicators and obfuscation patterns
  4. Detect encoded command execution and base64 payloads
  5. Identify download cradles, credential dumping, and lateral movement commands
  6. Score and prioritize findings by threat severity

Expected Output

json
{
  "total_events": 1247,
  "suspicious_events": 23,
  "amsi_bypass_attempts": 2,
  "encoded_commands": 8,
  "download_cradles": 5,
  "credential_access": 3
}

Archivos de esta versión

Permisos

PermisoDeclaradoHallado en el escaneo
Lee archivosNoNo
Escribe archivosNoNo
Ejecuta comandos de shellSíSí
Usa la redSíSí
Usa conectoresNoNo
Controla un navegadorNoNo

Hallazgos del escaneo

Revisado el 13 nov 2026

  1. MediaComando · command.pipe_to_shellreferences/api-reference.md:54
  2. MediaComando · command.pipe_to_shellreferences/api-reference.md:61
  3. MediaComando · command.base64_execreferences/api-reference.md:62
  4. MediaArchivo · Script ejecutable incluido con la skillscripts/agent.py
  5. MediaComando · command.pipe_to_shellscripts/agent.py:47
  6. MediaComando · command.pipe_to_shellscripts/agent.py:48
  7. MediaComando · command.base64_execscripts/agent.py:49
  8. InfoEnlace · Enlaces a dominios externos

Un escaneo limpio baja el riesgo, pero no prueba que el paquete sea seguro. Lee lo que instalas.

VersiónPublicadaCommitSHA-256FirmaCambio de permisos
v1.013 nov 202654a7988f7b57ee9Firmada–

Pregunta todo lo que tu alcance permite.

Crea la cuenta, añade créditos y haz la primera pregunta en el chat o en la terminal.

  1. 1/3

    Crea la cuenta

    Individual o empresa. Puedes pasar a empresa después sin perder saldo ni claves.

    IndividualEmpresa
  2. 2/3

    Añade créditos

    Con tarjeta. Pagas por token, sin suscripción.

    $5.00recarga mínima
  3. 3/3

    Pregunta

    En el chat, o instala el CLI y ejecuta notholy login en tu terminal.

    $ notholy login