本文へスキップ
Skillpedia
分析とスプレッドシート35k · #8221

performing-dns-tunneling-detection

できること

このツールはDNSの通信を分析し、データを隠すために悪用されることがある「DNSトンネリング」などの不審な活動を見つけます。DNSリクエストの名前や長さなどの詳細を確認し、通常とは異なる動きを特定します。

使う場面

  • ✓情報漏えいの可能性を調査するとき。
  • ✓セキュリティテスト中に、隠れたトンネルがないか確認するとき。
  • ✓悪意のある活動がないか、ネットワークの通信を分析するとき。

スキルのリンク

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/performing-dns-tunneling-detection/SKILL.md

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

使い方

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

貼り付け用メッセージ

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

AIへの頼み方の例

“このDNS通信のファイルを分析して、DNSトンネリングの兆候があるか教えてください。”

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

仕組み

ツールは、DNSリクエストの名前の「エントロピー」(ランダム性の度合い)を計算します。非常にランダムだったり、極端に長い名前は、データが隠されている可能性を示すことがあります。

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

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

Performing DNS Tunneling Detection

When to Use

  • When conducting security assessments that involve performing dns tunneling detection
  • When following incident response procedures for related security events
  • When performing scheduled security testing or auditing activities
  • When validating security controls through hands-on testing

Prerequisites

  • Familiarity with security operations concepts and tools
  • Access to a test or lab environment for safe execution
  • Python 3.8+ with required dependencies installed
  • Appropriate authorization for any testing activities

Instructions

Analyze DNS traffic for indicators of DNS tunneling using entropy analysis and statistical methods on query name characteristics.

import math
from collections import Counter

def shannon_entropy(data):
    if not data:
        return 0
    counter = Counter(data)
    length = len(data)
    return -sum((c/length) * math.log2(c/length) for c in counter.values())

# Legitimate domain: low entropy (~3.0-3.5)
print(shannon_entropy("www.google.com"))
# DNS tunnel: high entropy (~4.0-5.0)
print(shannon_entropy("aGVsbG8gd29ybGQ.tunnel.example.com"))

Key detection indicators:

  1. High Shannon entropy in query names (> 3.5 for subdomain labels)
  2. Unusually long query names (> 50 characters)
  3. High volume of TXT record requests to a single domain
  4. High unique subdomain count per parent domain
  5. Non-standard character distribution in labels

Examples

from scapy.all import rdpcap, DNS, DNSQR
packets = rdpcap("dns_traffic.pcap")
for pkt in packets:
    if pkt.haslayer(DNSQR):
        query = pkt[DNSQR].qname.decode()
        entropy = shannon_entropy(query)
        if entropy > 4.0:
            print(f"Suspicious: {query} (entropy={entropy:.2f})")
よくある質問

DNSトンネリングとは何ですか?

ファイアウォールなどのセキュリティ対策を回避するために、通常のDNSリクエストの中にデータを隠す手法です。

ここでエントロピーが重要なのはなぜですか?

通常のDNSリクエストには、ある程度の予測しやすさがあります。隠されたデータは、よりランダムになる傾向があるため、エントロピーが高くなります。

このツールを使うには、ネットワークの専門家である必要がありますか?

いいえ。ただし、結果を正しく解釈するには、ネットワークセキュリティの基礎知識があると役立ちます。

詳細

作者による元の説明

Detects DNS tunneling by computing Shannon entropy of DNS query names, analyzing query length distributions, inspecting TXT record payloads, and identifying high subdomain cardinality. Uses scapy for packet capture analysis and statistical methods to distinguish legitimate DNS from covert channels. Use when hunting for data exfiltration. '

repo: mukul975/Anthropic-Cybersecurity-Skills

人気

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

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

0

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

コメント

  • …

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

似ているスキル