Skip to content
Back to skills

Attack Tree

ASecurity

Build an attack tree for a stated attacker goal or asset, decomposing it into AND/OR sub-goals and leaf attack steps, then render it. Use when threat modeling, planning an engagement, or explaining how an asset could be compromised.

  • 8 stars
  • 0 votes
  • 0 copies
  • 4 views
  • Added September 19, 2026
ai-agentsgonodesecurity

Works with

  • mcp

Security analysis

A100/100

Scanned September 19, 2026

npx -y skills add jassics/awesome-claude-security --skill attack-tree --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Attack Tree?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Attack Tree
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/jassics-attack-tree/badge)](https://www.skillsdirectory.com/skills/jassics-attack-tree)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: attack-tree
description: >-
  Build an attack tree for a stated attacker goal or asset, decomposing it into
  AND/OR sub-goals and leaf attack steps, then render it. Use when threat
  modeling, planning an engagement, or explaining how an asset could be
  compromised.
---

# Goal

Produce a clear attack tree: a root attacker goal decomposed via AND/OR logic
into intermediate sub-goals and concrete leaf attacks, optionally annotated with
cost / difficulty / detectability, and rendered as a diagram.

# Steps

1. **Define the root.** Confirm the single attacker goal (e.g. "exfiltrate
   customer PII", "obtain domain admin"). One tree per goal.
2. **Decompose top-down.** Break the goal into sub-goals. Mark each node:
   - **OR** — any child achieves the parent (alternative paths).
   - **AND** — all children required together.
   Continue until leaves are concrete, actionable attack steps.
3. **Annotate leaves** (optional but recommended): cost, skill required,
   likelihood, and detectability. These drive prioritization and detection gaps.
4. **Identify cheapest/least-detectable path** to the root — that's the priority
   to mitigate and to build detections for.
5. **Render** with the `architecture-diagram` rendering approach: prefer the
   Excalidraw MCP; otherwise emit a Mermaid `flowchart TD` (root at top, AND
   nodes labeled, leaves as boxes) plus Graphviz DOT.

# Output

- The attack tree diagram (rendered or as importable Mermaid/DOT/Excalidraw JSON).
- A short table of leaf paths ranked by cost × likelihood ÷ detectability.
- A "mitigations & detections" list keyed to the highest-risk path.

# Notes

Use AND/OR semantics correctly — mislabeling changes the risk story. Keep node
labels short; put detail in the ranked table. Hand the ranked findings to
`security-reporting` if a writeup is needed.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.