agent-threat-rules: Command for Claude Code

.claude/commands/scan-skill.md

scan-skill is a command for Claude Code from Agent-Threat-Rule/agent-threat-rules. It costs 0 tokens per session (334 once invoked), scanned A, original, MIT.

A command for checking one MCP skill package, using either its npm package name or GitHub URL. MCP is a standard way for an AI agent to connect to external tools.

In plain words
What is it for?
It helps audit a single package, explain findings in plain language, identify triggered security rules, and prepare a security post when serious issues are found.
Why use it?
It helps reveal what a package claims to do, what it actually does, and any security findings before you use it.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

This is Agent-Threat-Rule/agent-threat-rules's own configuration. It tells Claude Code how to work on agent-threat-rules itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything agent-threat-rules configures →

Not installable: its command points at a path on the author’s own machine, so it runs nowhere else. The line is /Users/user/Downloads/agent-threat-rules.

Reuse

Borrowing it

Nothing to install: this file belongs to Agent-Threat-Rule/agent-threat-rules. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/Agent-Threat-Rule/agent-threat-rules/main/.claude/commands/scan-skill.md
Clone the repo
git clone --depth 1 https://github.com/Agent-Threat-Rule/agent-threat-rules

Made for: Claude Code.

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 scan-skill

README.md
[![agentmods](https://agentmods.dev/badge/commands/agent-threat-rule/agent-threat-rules/scan-skill.svg)](https://agentmods.dev/commands/agent-threat-rule/agent-threat-rules/scan-skill)
Your own site
<a href="https://agentmods.dev/commands/agent-threat-rule/agent-threat-rules/scan-skill"><img src="https://agentmods.dev/badge/commands/agent-threat-rule/agent-threat-rules/scan-skill.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 334 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00000 $0.00334
Opus 5 $0.00000 $0.00167
Sonnet 5 $0.00000 $0.00067
Haiku 4.5 $0.00000 $0.00033

Measured 8d ago against content hash c4606731137b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

scan-skill 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 8d 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.

.claude/commands/scan-skill.md · 36 lines

What it actually says

Scan Specific Skill

Scan a specific MCP skill by npm package name or GitHub URL.

Input

$ARGUMENTS — npm package name (e.g. mcp-server-filesystem) or GitHub URL

Steps

  1. If argument is a GitHub URL, extract the npm package name from package.json
  2. Run single-package audit:
cd /Users/user/Downloads/agent-threat-rules && npx tsx scripts/audit-npm-skills-v2.ts --limit 1 --offset 0 --output "data/scan-single-$(date +%Y%m%d%H%M%S).json"

Note: For single package scanning, we need to create a temporary registry entry. Instead:

cd /Users/user/Downloads/agent-threat-rules
mkdir -p /tmp/atr-single-scan
npm pack $ARGUMENTS --pack-destination /tmp/atr-single-scan 2>/dev/null
  1. If the package downloads successfully, run the ATR engine against it
  2. Present findings using the "Plain Language Consequences" template (T3):
    • What the skill claims to do
    • What it actually does (each finding in plain language)
    • What consequences the user faces
    • ATR rules triggered
  3. If CRITICAL or HIGH:
    • Generate a Skills Sec post draft using templates from templates/post-templates.json
    • Ask: "Post this? Which platforms?"
  4. If CLEAN:
    • Report clean status
    • Ask if I want to add to whitelist
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. 8d ago First seen · 36 lines · 0 tokens per session scan A c4606731137b

Subscribe to this mod's changes

scan-skill is a command published in the GitHub repository Agent-Threat-Rule/agent-threat-rules (385 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 334 tokens. 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.