auditor:threat-model

auditor:threat-model is a command for coding agents from solanabr/auditor-skill. It costs 140 tokens per session (1,045 once invoked), scanned A, original, MIT.

A security-review command that maps the system's important assets, actors, permissions, and trust boundaries before detailed findings are written.

In plain words
What is it for?
Use it to prepare a threat-model document for a code audit, including funds, authority, data, actor capabilities, and external interactions.
Why use it?
It clarifies what must be protected and which inputs or accounts cross security boundaries before judging risks.

Command

Part of the auditor plugin — 1 skill, 15 commands, 8 agents shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/solanabr/auditor-skill/threat-model
Clone the repo
git clone --depth 1 https://github.com/solanabr/auditor-skill

Or install auditor, the plugin that ships this one along with the rest of its 1 skill, 15 commands, 8 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for auditor:threat-model

README.md
[![agentmods](https://agentmods.dev/badge/commands/solanabr/auditor-skill/threat-model.svg)](https://agentmods.dev/commands/solanabr/auditor-skill/threat-model)
Your own site
<a href="https://agentmods.dev/commands/solanabr/auditor-skill/threat-model"><img src="https://agentmods.dev/badge/commands/solanabr/auditor-skill/threat-model.svg" alt="Measured on agentmods" height="20"></a>
Per session 140 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,045 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00140 $0.01045
Opus 5 $0.00070 $0.00522
Sonnet 5 $0.00028 $0.00209
Haiku 4.5 $0.00014 $0.00104

Measured 5d ago against content hash 2635bac5fd6a, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

auditor:threat-model scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/threat-model.md · 44 lines

How it starts

The opening of the file, as written. The whole thing — 44 lines — stays where its author put it; the contents beside it link to each section on GitHub.

auditor-skill — Pre-Review Threat Model

Arguments: $ARGUMENTS

Build the threat model before the manual review judges anything — analogous to how context reconstruction (Phase 0.5) precedes verdicts. Read templates/threat-model.md (the artifact you fill) and the report sections it feeds: templates/audit-report.md §4.4 (Trust Model & Actors), §4.6 (Assumptions & Simplifications), §4.7 (Systemic / Thematic Risks). This is target enumeration, not a findings document — no severities, no verdicts.

Inputs

  • The in-scope code (instructions, accounts, PDAs, CPIs, arithmetic).
  • audit_<n>/intake.md §6 — the trust-model inputs (who is trusted). The actor list to expand. Read it if present; if absent, run /auditor:intake first or reconstruct actors from the code and note intake was unavailable.
  • audit_<n>/worksheets/context/*context-builder's invariants, assumptions, and external-interaction risks, if the context phase has run.
  • audit-mem warm <program-id> prior invariants + open FP rulings, if tools/auditor-tools is built (skip cleanly otherwise).

Mode

  • Automated (--auto, the audit-cycle path) — spawn the threat-modeler agent (opus). It reconstructs the three artifacts from code + context worksheets and emits audit_<n>/threat-model.md, every claim cited to file:line.
  • Interactive (default) — ask the human the model questions a tool cannot settle: which assets are the crown jewels, which actors are genuinely trusted vs. untrusted, what each actor must be prevented from doing. Fill the artifact from their answers plus the code.

What to build

Fill templates/threat-model.md:

  1. Asset inventory — crown-jewel assets by class (funds / authority / data), where each lives (account / PDA), cited to definition/holding site, and the worst case if compromised. Aligns to report §4.2.
  2. Actor × capability table — for each actor (permissionless user / LP / keeper / admin / upgrade authority / oracle / CPI callee): trust level, what they can do (→ the instruction @ file:line), and — the load-bearing column — what they must NOT be able to do. Column layout aligns to report §4.4 (Privileges / Trust Assumption); the "must NOT" cells are the security properties the reviewers test.
  3. Trust-boundary map — every CPI, caller-supplied account, instruction arg, remaining_accounts, and sysvar that crosses from lower to higher trust, cited, with whether it is validated (cite the guard or mark ). Feeds report §4.6 (what is trusted) and §4.7 (transitive/indirect CPI risk).
  4. Attacker goals to test — derived from the "must NOT" cells and the unvalidated crossings, each mapped to the checklists / known-vectors that hunt it. These are the goals vuln-hunter and economic-analyst try to achieve; a goal that turns out reachable becomes a finding downstream through the Rule 5b gate.

Read the full file on GitHub · 44 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 44 lines · 140 tokens per session scan A 2635bac5fd6a

Subscribe to this mod's changes

auditor:threat-model is a command published in the GitHub repository solanabr/auditor-skill (53 stars, last pushed 2d ago), licensed MIT. It adds 140 tokens to every session and 1,045 once invoked, about $0.0007 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.