本文へスキップ
Skillpedia
エージェント35k · #7855

detecting-ntlm-relay-with-event-correlation

できること

このツールは、NTLMリレー攻撃を見つけるのに役立ちます。接続元のコンピューターが、想定されているものと異なるIPアドレスから接続していないかを確認します。これは、ログイン認証情報が傍受され、転送されている可能性を示します。

使う場面

  • ✓NTLM認証を使用しているネットワークで、ログイン認証情報が盗まれている疑いがあるとき。
  • ✓コンピューターが想定外の場所から別のコンピューターに接続したときの原因を調べるとき。
  • ✓重要なシステムが認証リレー攻撃から守られているかを確認するとき。

スキルのリンク

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-ntlm-relay-with-event-correlation/SKILL.md

コピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。

使い方

いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。

貼り付け用メッセージ

このスキルを使って手伝ってください:https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/detecting-ntlm-relay-with-event-correlation/SKILL.md このリンクのSKILL.mdファイルを読んで、私の作業でその指示に従ってください。
こういうスキルを、AIが自分で見つけてくれたら?無料のSkillpedia MCPをインストール。1行で、作業の前に15,000+のスキルから探してくれます。1分でインストール →

AIへの頼み方の例

“盗まれたログイン認証情報を使った不正アクセスの試みがないか確認して。”

毎週5つの新しいスキル。1分で読めます。

仕組み

このツールはWindowsのイベントログを分析し、接続元のコンピューター名と、実際に接続してきたIPアドレスが一致しない接続を探します。また、リレー攻撃で使われる一般的なツールの痕跡も探します。

技術的な内容(元のSKILL.md)

作者による元のテキスト(英語)をGitHubからそのまま表示しています。

Detecting NTLM Relay with Event Correlation

Authorized Testing Disclaimer: The offensive techniques and attack simulations described in this skill are intended exclusively for authorized penetration testing, red team engagements, purple team exercises, and security research conducted with explicit written permission from the system owner. Unauthorized use of these techniques against systems you do not own or have permission to test is illegal and unethical. Always operate within the scope of your engagement and comply with applicable laws and regulations.

Overview

NTLM relay attacks intercept NTLM authentication messages and forward them to a target service to gain unauthorized access. Attackers use tools like Responder for LLMNR/NBT-NS/mDNS poisoning, ntlmrelayx (Fox-IT/Impacket) for multi-protocol relay, and coercion techniques like PetitPotam (MS-EFSRPC) and DFSCoerce to force authentication from high-value targets like domain controllers. This skill provides a comprehensive event correlation framework using Windows Security Event 4624 LogonType 3 analysis, IP-to-hostname mismatch detection, Responder traffic identification, SMB/LDAP signing audit, and NTLM downgrade detection to identify relay attacks across Active Directory environments.

When to Use

  • Hunting for credential relay activity in Active Directory environments where NTLM authentication is still in use
  • Investigating alerts for authentication anomalies where the source IP does not match the expected workstation
  • Auditing SMB signing and LDAP signing enforcement to assess exposure to relay attacks
  • Detecting NTLM downgrade attacks where NTLMv2 is forced to NTLMv1 for easier offline cracking or relay
  • Building SIEM correlation rules for MITRE ATT&CK T1557.001 (LLMNR/NBT-NS Poisoning and SMB Relay)
  • Responding to PetitPotam, DFSCoerce, or PrinterBug coercion alerts that may precede relay attacks
  • During purple team exercises validating NTLM relay detection and SMB signing enforcement

Do not use without centralized Windows Security Event Log collection, as a substitute for enforcing SMB signing and Extended Protection for Authentication (EPA) which prevent relay attacks at the protocol level, or without an IP-to-hostname inventory for correlation.

Prerequisites

  • Windows Advanced Audit Policy configured to capture Event IDs 4624, 4625, 4648, 4776, and 8004
  • Centralized log collection via Windows Event Forwarding (WEF) or agent-based shipping to SIEM
  • SIEM platform (Splunk, Elastic, Microsoft Sentinel) with correlation and alerting capability
  • IP address to hostname mapping inventory (DHCP logs, DNS records, or CMDB)
  • Network monitoring for LLMNR (UDP 5355), NBT-NS (UDP 137), and mDNS (UDP 5353) traffic
  • Understanding of MITRE ATT&CK T1557.001 and T1187 (Forced Authentication)

Workflow

Step 1: Understand NTLM Relay Attack Flow

The NTLM relay attack follows a three-phase pattern: coercion/poisoning, interception, and relay.

Phase 1 -- Coercion or Poisoning: The attacker forces or tricks a victim into initiating NTLM authentication. Methods include LLMNR/NBT-NS poisoning (Responder), PetitPotam (MS-EFSRPC abuse), PrinterBug (SpoolService), and DFSCoerce.

Phase 2 -- Interception: The attacker captures the NTLM Type 1 (Negotiate) and Type 3 (Authenticate) messages from the victim.

Phase 3 -- Relay: The attacker forwards the captured NTLM messages to a target service (SMB, LDAP, HTTP, MSSQL) to authenticate as the victim. This succeeds only when message signing is not enforced.

Victim ──NTLM Negotiate──> Attacker ──NTLM Negotiate──> Target
Victim <──NTLM Challenge── Attacker <──NTLM Challenge── Target
Victim ──NTLM Authenticate──> Attacker ──NTLM Authenticate──> Target
                                                         ↓
                                              Attacker authenticated
                                              as Victim on Target

Key Detection Insight: In a relay attack, Event 4624 on the target will show the victim's username but the attacker's IP address. The WorkstationName field may still reflect the victim's machine. This IP-to-hostname mismatch is the primary detection signal.

Step 2: Event 4624 LogonType 3 Analysis for Relay Detection

# Splunk: Detect IP-to-Hostname Mismatches in Network Logons
# Core NTLM relay detection -- correlates WorkstationName with IpAddress

index=wineventlog EventCode=4624 LogonType=3

…
よくある質問

NTLMリレー攻撃とは何ですか?

攻撃者がNTLMプロトコルを使ったユーザーのログイン認証情報を傍受し、それを別のシステムに転送して、ユーザーになりすまし不正にアクセスする攻撃です。

イベント4624 LogonType 3とは何ですか?

ネットワークログオンを示すWindowsのログ記録です。他の情報と組み合わせることで、リレー攻撃のような不審な活動の特定に役立ちます。

IPアドレスとホスト名の照合が重要なのはなぜですか?

通常、コンピューター名は特定のIPアドレスと結び付いています。既知のコンピューター名を名乗る接続が想定外のIPアドレスから来ている場合、攻撃が進行中である可能性があります。

詳細

作者による元の説明

Detect NTLM relay attacks (T1557.001) by correlating Windows Event 4624 LogonType 3 for IP-to-hostname mismatches, identifying Responder/LLMNR poisoning artifacts, auditing SMB/LDAP signing, and flagging NTLMv2-to-NTLMv1 downgrades. Use for hunting credential relay in NTLM-enabled AD, investigating auth-source anomalies, building SIEM correlation rules, or responding to PetitPotam/DFSCoerce/Printe

repo: mukul975/Anthropic-Cybersecurity-Skills

人気

GitHubのスター
35k
ランキング
#7855
ライセンス
Apache-2.0
更新日
2026/8/31

このスキルは役に立ちますか?

0

ログイン して投票しましょう。

コメント

  • …

このリポジトリの他のスキル

似ているスキル