/cybersecurity-skills-zh:performing-dns-tunneling-detectionfrom cybersecurity-skills-zh
Detects DNS tunneling attacks by analyzing Shannon entropy, query length, TXT record payloads, and subdomain counts using scapy for packet capture.
Ships in cybersecurity-skills-zh. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
使用熵分析和统计方法对查询名称特征进行分析,检测 DNS 流量中的 DNS 隧道指标。
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())
# 合法域名:低熵(~3.0-3.5)
print(shannon_entropy("www.google.com"))
# DNS 隧道:高熵(~4.0-5.0)
print(shannon_entropy("aGVsbG8gd29ybGQ.tunnel.example.com"))
关键检测指标:
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"可疑:{query}(entropy={entropy:.2f})")
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub killvxk/cybersecurity-skills-zh --plugin cybersecurity-skills-zh735 skills in this plugin
/acquiring-disk-image-with-dd-and-dcfldd使用 dd 和 dcfldd 创建取证级逐位磁盘镜像,通过哈希验证保持证据完整性。/analyzing-active-directory-acl-abuse使用 ldap3 检测 Active Directory 中危险的 ACL 配置错误,识别 GenericAll、WriteDACL 和 WriteOwner 等滥用路径/analyzing-android-malware-with-apktool使用 apktool 进行反编译、jadx 恢复 Java 源码、androguard 进行权限分析,对 Android APK 恶意软件样本执行静态分析,包括清单检查和可疑 API 调用检测。Other plugins' skills for the same job