Перейти к содержимому
New

DeepSeek V4.1 Flash free for 7 days: 10M tokens a day after a top-up of $10 or more. Until Nov 30.

How it works
mukul975/hunting-for-anomalous-powershell-executionDFIR и threat hunting

hunting-for-anomalous-powershell-execution

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

v1.03 установки+3 за 7 дней36,3 тыс. ЗвездыApache-2.0синхронизировано 12 часов назад

Установка

Ещё нет NotHoly CLI? Сначала установите её.

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

Пишет в ⁦~/.notholy/skills⁩ после проверки подписи и SHA-256.

ПодписьПодписано, ed25519
wcM7M8t+my…3smyI5AA==CLI проверяет SHA-256 и подпись, прежде чем записать хоть один файл.
Пакетf7b57ee9…9347c8a0
f7b57ee96d70…cb469347c8a04 файла · ⁦9.2 KB⁩
ПроверкаСредний8 замечаний
  • command.pipe_to_shellreferences/api-reference.md:54
  • command.pipe_to_shellreferences/api-reference.md:61
  • command.base64_execreferences/api-reference.md:62
Вся проверка
Источникgithub.com/mukul975/Anthropic-Cybersecurity-Skills/tree/main/skills/hunting-for-anomalous-powershell-execution@54a7988

Эта запись еще не переведена на русский, поэтому показан текст на другом языке: 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
}

Файлы этой версии

Права

ПравоЗаявленоНайдено проверкой
Читает файлыНетНет
Пишет файлыНетНет
Выполняет команды shellДаДа
Ходит в сетьДаДа
Использует коннекторыНетНет
Управляет браузеромНетНет

Замечания проверки

Проверено 13 нояб. 2026 г.

  1. СредняяКоманда · command.pipe_to_shellreferences/api-reference.md:54
  2. СредняяКоманда · command.pipe_to_shellreferences/api-reference.md:61
  3. СредняяКоманда · command.base64_execreferences/api-reference.md:62
  4. СредняяФайл · Исполняемый скрипт в составе навыкаscripts/agent.py
  5. СредняяКоманда · command.pipe_to_shellscripts/agent.py:47
  6. СредняяКоманда · command.pipe_to_shellscripts/agent.py:48
  7. СредняяКоманда · command.base64_execscripts/agent.py:49
  8. ИнфоСсылка · Ссылки на внешние домены

Чистая проверка снижает риск, но не доказывает, что пакет безопасен. Читайте то, что ставите.

ВерсияОпубликованаКоммитSHA-256ПодписьИзменение прав
v1.013 нояб. 2026 г.54a7988f7b57ee9Подписана–

Спрашивайте обо всём, что позволяет ваш скоуп.

Создайте аккаунт, пополните баланс и задайте первый вопрос в чате или в терминале.

  1. 1/3

    Создайте аккаунт

    Личный или для компании. Позже можно перейти на аккаунт компании без потери баланса и ключей.

    ЛичныйКомпания
  2. 2/3

    Пополните баланс

    Картой. Оплата за токены, без подписки.

    $5.00минимальное пополнение
  3. 3/3

    Спрашивайте

    В чате, или установите CLI и выполните notholy login в терминале.

    $ notholy login