Anthropic-Cybersecurity-Skills 完整教學

1. 專案定位與核心價值

解決什麼問題

根據 ISC2 報告,2024 年全球資安人才缺口達 480 萬人。AI agent 可以協助填補這個缺口,但前提是必須具備結構化的領域知識。現有的資安工具庫提供的是 wordlist、payload 或 exploit 程式碼,而非資深分析師的決策工作流程。

Anthropic-Cybersecurity-Skills 填補了這個空缺:它不是腳本集或檢查清單,而是一套 AI 原生知識庫 (AI-native knowledge base),讓任何 AI agent 瞬間具備資深資安分析師的結構化操作能力。

核心數據

指標數值
技能總數817
安全領域29
對應框架6(ATT&CK + NIST CSF 2.0 + ATLAS + D3FEND + AI RMF + F3)
支援平台26+
GitHub Stars21,163
授權Apache 2.0
最新版本v1.3.0 (2026-06-22)

為什麼不是另一個資安工具庫

傳統資安工具庫與本專案的根本差異:

維度傳統工具庫本專案
內容形式可執行腳本、payload結構化知識文件
目標使用者人類操作員AI agent
發現機制人工瀏覽 READMEYAML frontmatter ~30 token 自動發現
執行邏輯直接執行逐步工作流指引
框架對應無或部分6 大框架完整對應

2. 安裝與環境設定

方法一:npx 一鍵安裝(推薦)

1# 安裝到當前 AI agent 工作環境
2npx skills add mukul975/Anthropic-Cybersecurity-Skills

此方式適用於所有支援 agentskills.io 標準的平台。

方法二:Git Clone

1# 完整 clone
2git clone https://github.com/mukul975/Anthropic-Cybersecurity-Skills.git
3cd Anthropic-Cybersecurity-Skills
4
5# 或 shallow clone(僅最新版本,節省空間)
6git clone --depth 1 https://github.com/mukul975/Anthropic-Cybersecurity-Skills.git

方法三:Claude Code Plugin

本專案已封裝為 .claude-plugin 格式。Clone 後,Claude Code 會自動偵測 .claude-plugin/plugin.json 並載入全部 817 個技能。

環境需求

  • 必要:Git
  • 建議:Python 3.7+(部分技能附帶輔助腳本)
  • 可選:Node.js(npx 安裝方式)
  • 空間:完整 clone 約需數百 MB(817 個技能目錄)

驗證安裝

1# 確認技能總數
2ls -d skills/*/ | wc -l
3# 預期輸出:817
4
5# 確認 index.json 可讀
6cat index.json | python3 -c "import sys,json; d=json.load(sys.stdin); print(f'Skills indexed: {len(d[\"skills\"])}')"
7
8# 驗證特定技能
9cat skills/performing-memory-forensics-with-volatility3/SKILL.md | head -20

3. 核心架構解析

整體架構


graph TB
    subgraph "Anthropic-Cybersecurity-Skills 架構"
        direction TB
        
        subgraph "入口層 Entry Layer"
            IDX["index.json
817 技能索引"] PLG[".claude-plugin/
plugin.json + marketplace.json"] NPX["npx skills add
agentskills.io 標準安裝"] end subgraph "技能層 Skills Layer — 29 Domains" direction LR S1["Cloud Security
66 skills"] S2["Threat Hunting
58 skills"] S3["Threat Intel
52 skills"] S4["Network Security
43 skills"] S5["Web App Sec
42 skills"] S6["Digital Forensics
41 skills"] S7["...23 more domains"] end subgraph "單一技能結構 Skill Anatomy" direction TB FM["YAML Frontmatter
~30 tokens 自動發現"] MD["Markdown Body
When to Use / Prerequisites /
Workflow / Verification"] REF["references/
standards.md + workflows.md"] SCR["scripts/
agent.py + process.py"] AST["assets/
template.md"] end subgraph "框架對應層 Framework Mappings" ATT["MITRE ATT&CK v19.1
15 tactics / 286 techniques"] CSF["NIST CSF 2.0
6 functions / 22 categories"] ATL["MITRE ATLAS v5.4
16 tactics / 84 techniques"] D3F["MITRE D3FEND v1.3
7 categories / 267 techniques"] RMF["NIST AI RMF 1.0
4 functions / 72 subcategories"] F3["MITRE F3 v1.1
8 tactics / 123 techniques"] end subgraph "AI Agent 消費層" AG1["Claude Code"] AG2["GitHub Copilot"] AG3["Cursor / Windsurf"] AG4["Codex CLI / Gemini CLI"] AG5["LangChain / CrewAI"] end end NPX --> IDX PLG --> IDX IDX --> S1 & S2 & S3 & S4 & S5 & S6 & S7 S1 & S2 & S3 --> FM FM --> MD --> REF & SCR & AST FM --> ATT & CSF & ATL & D3F & RMF & F3 IDX --> AG1 & AG2 & AG3 & AG4 & AG5

Progressive Disclosure 架構

本專案最核心的設計決策是 漸進式揭露 (Progressive Disclosure)

  1. 第一層:Frontmatter 掃描 (~30 tokens/skill) — AI agent 可在單次 pass 掃描全部 817 個技能的 YAML frontmatter,根據 namedescriptiontagssubdomain 匹配相關技能
  2. 第二層:Markdown Body 載入 (~500-2,000 tokens/skill) — 載入匹配技能的完整工作流程
  3. 第三層:深度參考 — 視需要載入 references/scripts/

這個設計讓 agent 在不爆 context window 的前提下,搜尋所有 817 個技能。

技能 Frontmatter Schema

 1---
 2name: kebab-case-name           # 1-64 字元
 3description: >-                  # 關鍵字豐富,供 agent 發現
 4  Clear description of what 
 5  this skill does
 6domain: cybersecurity            # 固定值
 7subdomain: digital-forensics     # 29 個合法值之一
 8tags: [tag1, tag2, tag3]         # 工具名、技術名、框架名
 9version: "1.0"
10author: github-username
11license: Apache-2.0
12# 框架對應(可選)
13nist_csf: [DE.CM-01, RS.AN-03]
14mitre_attack: [T1005, T1074]
15atlas_techniques: [AML.T0047]
16d3fend_techniques: [D3-MA, D3-PSMD]
17nist_ai_rmf: [MEASURE-2.6]
18mitre_f3: [F1005.006]
19---

目錄結構

 1Anthropic-Cybersecurity-Skills/
 2├── index.json                     全部 817 技能的索引
 3├── .claude-plugin/                Claude Code plugin 定義
 4   ├── plugin.json
 5   └── marketplace.json
 6├── skills/                        817 個技能目錄
 7   ├── performing-memory-forensics-with-volatility3/
 8      ├── SKILL.md
 9      ├── references/
10      ├── scripts/
11      └── assets/
12   └── ...
13├── mappings/                      框架對應資料
14   ├── attack-navigator-layer.json
15   ├── mitre-attack/
16   ├── nist-csf/
17   └── owasp/
18├── tools/
19   └── validate-skill.py          技能驗證工具
20├── docs/
21   └── mitre-f3-mapping.md        F3 對應說明
22├── CONTRIBUTING.md                貢獻指南
23├── SECURITY.md                    安全政策
24├── CITATION.cff                   學術引用
25└── ATTACK_COVERAGE.md             ATT&CK 覆蓋率報告

4. 主要功能詳解

4.1 技能搜尋與發現

AI agent 使用技能的流程:

  1. 掃描 index.json — 取得全部技能清單與 frontmatter 摘要
  2. 關鍵字匹配 — 根據使用者 prompt 匹配 descriptiontagssubdomain
  3. 載入最佳匹配 — 讀取完整 SKILL.md 的 Markdown body
  4. 逐步執行 — 依照 Workflow section 的步驟操作

實際範例:

 1使用者提問:"分析這個 memory dump 是否有 credential theft 跡象"
 2
 3Agent 內部流程:
 4  1. 掃描 817 個 frontmatter (~30 tokens each)
 5     → 識別出 12 個相關技能
 6  2. 載入前 3 匹配:
 7     • performing-memory-forensics-with-volatility3
 8     • hunting-for-credential-dumping-lsass
 9     • analyzing-windows-event-logs-for-credential-access
10  3. 執行 Workflow section 的逐步指令
11  4. 使用 Verification section 確認結果

4.2 六大框架對應

每個技能可同時對應多個框架。以 analyzing-network-traffic-of-malware 為例:

框架對應 ID
ATT&CKT1071 (Application Layer Protocol)
NIST CSFDE.CM (Continuous Monitoring)
ATLASAML.T0047
D3FENDD3-NTA (Network Traffic Analysis)
AI RMFMEASURE-2.6
F3

4.3 MITRE Fight Fraud Framework (F3) — 新增亮點

F3 v1.1 由 MITRE CTID 與 JPMorganChase、Citigroup 等機構共同開發,填補了 ATT&CK 在 金融詐欺 領域的缺口:

  • Positioning (FA0001) — 取得存取後的詐欺準備行動(合成身份植入、帳戶暖場、受益人設定等)
  • Monetization (FA0002) — 將竊取資產轉換為可用資金(錢騾洗錢、APP 詐欺、加密貨幣出金等)

本專案已對應 94 個 fraud-relevant skills 到 F3 的 123 個技術 ID。

4.4 技能驗證工具

1# 驗證單一技能
2python tools/validate-skill.py skills/performing-memory-forensics-with-volatility3/
3
4# 驗證全部技能
5python tools/validate-skill.py --all

驗證項目包含:

  • Frontmatter 必要欄位檢查 (name, description, domain, subdomain, tags)
  • name 格式驗證(kebab-case, 1-64 字元)
  • subdomain 合法值檢查(29 個合法值 + alias)
  • Workflow section 完整性

4.5 ATT&CK Navigator Layer

Release assets 包含 attack-navigator-layer.json,可直接匯入 MITRE ATT&CK Navigator 做視覺化覆蓋率分析。

5. 應用場景與實戰範例

場景一:SOC 告警分類自動化

資安營運中心 (SOC) 每天面對數百到數千筆告警。將本技能庫載入 AI agent 後:

 1告警:偵測到異常 PowerShell 活動
 2
 3Agent 自動匹配技能:
 4  • analyzing-powershell-script-block-logging
 5  • detecting-suspicious-powershell-execution
 6  • detecting-fileless-attacks-on-endpoints
 7
 8Agent 執行工作流:
 9  1. 檢查 PowerShell Script Block Logging (Event ID 4104)
10  2. 分析編碼命令 (-EncodedCommand)
11  3. 檢查是否有 AMSI bypass 嘗試
12  4. 比對 MITRE ATT&CK T1059.001
13  5. 產出結構化分析報告

場景二:雲端安全稽核

 1任務:稽核 AWS 環境安全態勢
 2
 3Agent 載入技能:
 4  • implementing-cloud-trail-log-analysis
 5  • implementing-aws-security-hub-compliance
 6  • detecting-cryptomining-in-cloud
 7
 8執行結果:
 9  • CloudTrail 日誌完整性驗證
10  • Security Hub 合規標準對應(CIS、PCI DSS)
11  • 異常 EC2 實例行為偵測

場景三:紅隊演練知識庫

 1目標:內部 Active Directory 滲透測試
 2
 3Agent 載入技能:
 4  • exploiting-adcs-with-certipy (ADCS ESC1)
 5  • conducting-internal-reconnaissance-with-bloodhound-ce
 6  • exploiting-kerberoasting-with-impacket
 7  • performing-lateral-movement-with-wmiexec
 8
 9每個技能提供:
10  • 前置條件檢查
11  • 逐步工具命令
12  • 預期輸出範例
13  • 驗證步驟

場景四:事件回應 (Incident Response)

 1情境:疑似勒索軟體入侵
 2
 3Agent 載入技能:
 4  • performing-memory-forensics-with-volatility3
 5  • building-super-timelines-with-plaso
 6  • performing-ransomware-tabletop-exercise
 7
 8IR 工作流:
 9  1. 記憶體取證 → 識別惡意程序
10  2. 建立超級時間軸 → 還原攻擊鏈
11  3. 比對 ATT&CK 戰術 → 確認攻擊階段
12  4. 執行封鎖與復原程序

場景五:AI/ML 安全評估

 1任務:評估 LLM 應用的安全風險
 2
 3Agent 載入技能(AI Security 領域,14 個技能):
 4  • detecting-model-extraction-attacks
 5  • LLM red-teaming (garak/PyRIT)
 6  • prompt injection 防禦
 7  • MCP/agentic security 評估
 8
 9對應框架:
10  • MITRE ATLAS v5.4 — AI 特有攻擊向量
11  • NIST AI RMF — AI 風險管理

6. 資安掃描報告

掃描範圍

對 repository 內全部 Python 腳本 (.py)、Shell 腳本 (.sh)、JavaScript/TypeScript (.js/.ts)、Markdown 文件 (.md) 進行關鍵字掃描。

掃描結果

項目結果
eval / exec / os.system未偵測到可執行程式碼中的危險呼叫
subprocess / shell=True未偵測到
pickle / __import__未偵測到
curl / wget僅出現在 Markdown 教學文件中(安裝指引)
secret / token / password / api_key僅出現在 JWT 測試技能的弱密碼字典(教學用途)

風險評估

🟢 低風險 (Low Risk)

  • 所有 Python 腳本 (agent.py, process.py) 為輔助分析工具,不含危險系統呼叫
  • secret / password 等字串僅出現在 JWT 弱密碼字典(skills/testing-for-json-web-token-vulnerabilities/scripts/agent.py),為合法的安全測試用途
  • Markdown 中的 curl / wget 為工具安裝指引,非自動執行
  • 無硬編碼的 API key、token 或認證資訊
  • 兩個 Windows Defender 誤判案例 (Issues #79, #33) 已被確認為因技能內容涉及攻擊技術描述而觸發

注意事項

  • 技能內容涉及滲透測試、惡意軟體分析等攻擊性技術,使用時需遵守法律法規與授權範圍
  • 部分技能引用第三方工具(Volatility3、BloodHound、Sliver 等),使用前需自行評估這些工具的安全性
  • Windows Defender 可能將部分技能文件標記為惡意軟體,需加入排除清單

7. FAQ 常見問題

Q1:這個專案跟 Anthropic 有關係嗎?

沒有。專案名稱雖含 “Anthropic”,但這是獨立的社群專案,與 Anthropic PBC 無官方關聯。README 頂部已明確標示 “Community Project”。

Q2:817 個技能會不會炸掉 AI agent 的 context window?

不會。專案採用 Progressive Disclosure 設計:frontmatter 掃描每個技能只需 ~30 tokens,完整載入才需 500-2,000 tokens。Agent 通常只載入最匹配的 3-5 個技能。

Q3:這些技能可以直接用來攻擊嗎?

技能是「知識文件」而非「攻擊工具」。它們描述的是分析流程和工作步驟,不包含可直接執行的 exploit。使用時仍需遵守法律法規,僅在授權範圍內操作。

Q4:如何貢獻新技能?

  1. Fork 專案
  2. 建立 skills/your-skill-name/ 目錄
  3. 撰寫 SKILL.md(含必要 YAML frontmatter)
  4. 執行 python tools/validate-skill.py skills/your-skill-name/ 驗證
  5. 提交 PR(標題格式:Add skill: your-skill-name

Q5:Windows Defender 標記我的 clone 為惡意軟體怎麼辦?

已知問題(#79, #33)。在 Windows Defender 中為 clone 目錄新增排除項目即可。這是因為技能文件中描述了攻擊技術而觸發了啟發式偵測。

Q6:index.json 是手動維護的嗎?

不是。從 commit 歷史可以看到 chore: auto-update index.json and skill count 的自動更新機制,每次新增技能後會自動重建索引。

Q7:如何查看特定 ATT&CK 技術的覆蓋率?

  • 查看 ATTACK_COVERAGE.md — 完整的 technique-to-skill 對應表
  • 匯入 mappings/attack-navigator-layer.json 到 ATT&CK Navigator 做視覺化

8. 進階技巧

8.1 自訂技能子集

若不需要全部 817 個技能,可依 subdomain 篩選:

1# 只保留 cloud-security 相關技能
2mkdir -p my-skills/skills
3for d in skills/*/; do
4  if grep -q 'subdomain: cloud-security' "$d/SKILL.md" 2>/dev/null; then
5    cp -r "$d" my-skills/skills/
6  fi
7done
8echo "Cloud security skills: $(ls -d my-skills/skills/*/ | wc -l)"

8.2 建立自訂索引

 1import os, yaml, json
 2
 3skills = []
 4for d in sorted(os.listdir('skills')):
 5    skill_path = f'skills/{d}/SKILL.md'
 6    if os.path.exists(skill_path):
 7        with open(skill_path) as f:
 8            # 讀取 YAML frontmatter
 9            content = f.read()
10            if content.startswith('---'):
11                fm = content.split('---')[1]
12                meta = yaml.safe_load(fm)
13                skills.append(meta)
14
15with open('my-index.json', 'w') as f:
16    json.dump({'skills': skills, 'count': len(skills)}, f, indent=2)
17print(f'Indexed {len(skills)} skills')

8.3 框架合規查詢

1# 查詢所有對應到 NIST CSF DE.CM(持續監控)的技能
2grep -rl 'DE.CM' skills/*/SKILL.md | while read f; do
3  dir=$(dirname "$f")
4  echo "$(basename $dir)"
5done
6
7# 查詢所有對應到特定 ATT&CK technique 的技能
8grep -rl 'T1059' skills/*/SKILL.md | wc -l

8.4 與 validate-skill.py 整合 CI/CD

 1# .github/workflows/validate.yml
 2name: Validate Skills
 3on: [push, pull_request]
 4jobs:
 5  validate:
 6    runs-on: ubuntu-latest
 7    steps:
 8      - uses: actions/checkout@v4
 9      - uses: actions/setup-python@v5
10        with:
11          python-version: '3.11'
12      - run: python tools/validate-skill.py --all

8.5 ATT&CK Navigator 視覺化

1# 下載 navigator layer
2curl -LO https://github.com/mukul975/Anthropic-Cybersecurity-Skills/releases/download/v1.0.0/attack-navigator-layer.json
3
4# 開啟 ATT&CK Navigator
5# https://mitre-attack.github.io/attack-navigator/
6# → Open Existing Layer → Upload from Local → 選擇下載的 JSON

9. 整合進其他工作流

9.1 整合到 Claude Code 工作環境

1# 方法一:作為 plugin 安裝
2cd your-project
3npx skills add mukul975/Anthropic-Cybersecurity-Skills
4
5# 方法二:作為 submodule
6git submodule add https://github.com/mukul975/Anthropic-Cybersecurity-Skills.git .claude/cybersecurity-skills

安裝後,Claude Code 在收到資安相關提問時會自動搜尋並載入相關技能。

9.2 整合到 LangChain Agent

 1from langchain.tools import Tool
 2import os, yaml
 3
 4def load_cybersecurity_skill(skill_name: str) -> str:
 5    """載入指定的資安技能完整內容"""
 6    path = f"skills/{skill_name}/SKILL.md"
 7    if os.path.exists(path):
 8        with open(path) as f:
 9            return f.read()
10    return f"Skill '{skill_name}' not found"
11
12cybersec_tool = Tool(
13    name="cybersecurity_skill",
14    description="Load structured cybersecurity skill by name",
15    func=load_cybersecurity_skill
16)

9.3 與 SIEM 整合

技能中的 MITRE ATT&CK 對應可直接與 SIEM 的告警規則關聯:

1SIEM 告警觸發 ATT&CK T1059.001 (PowerShell)
23查詢 index.json 匹配 mitre_attack: T1059
45載入相關技能的 Workflow section
67AI agent 依工作流分析告警並產出報告

9.4 搭配 Sigma Rules 使用

1# 找到所有引用 Sigma 的技能
2grep -rl -i 'sigma' skills/*/SKILL.md | head -10
3
4# 技能中的 Sigma 規則參考可直接匯入 SIEM

9.5 與 SOAR 平台整合

技能的結構化 Workflow section 可作為 SOAR playbook 的知識來源,讓自動化回應流程具備專家級判斷邏輯。

10. 重點摘要 Checklist

  • 理解定位:AI 原生資安知識庫,非攻擊工具集
  • 安裝方式npx skills addgit clone --depth 1
  • 架構核心:Progressive Disclosure — frontmatter (~30 tokens) → body (~500-2,000 tokens) → references
  • 技能結構:SKILL.md (frontmatter + 4 sections) + references/ + scripts/ + assets/
  • 六大框架:ATT&CK v19.1 + NIST CSF 2.0 + ATLAS v5.4 + D3FEND v1.3 + AI RMF 1.0 + F3 v1.1
  • 29 個領域:從 Cloud Security (66) 到 Hardware & Firmware Security (4)
  • 驗證工具python tools/validate-skill.py --all
  • 安全評估:🟢 低風險 — 知識文件為主,無危險可執行程式碼
  • 貢獻方式:Fork → 建目錄 → 寫 SKILL.md → validate → PR
  • 平台相容:26+ 平台,任何 agentskills.io 相容工具皆可用
  • 框架查詢:ATT&CK Navigator layer + ATTACK_COVERAGE.md + grep frontmatter
  • Windows 使用者:可能需為 clone 目錄新增 Defender 排除項目

11. 進一步閱讀與參考資源

官方資源

框架文件

相關工具

收錄於

學術引用

1@software{anthropic_cybersecurity_skills,
2  author       = {Jangra, Mahipal},
3  title        = {Anthropic Cybersecurity Skills},
4  year         = {2026},
5  url          = {https://github.com/mukul975/Anthropic-Cybersecurity-Skills},
6  license      = {Apache-2.0}
7}