fastapi-security-audit

fastapi-security-audit is a skill for Claude Code from steph-dove/klaussy-agents. It costs 0 tokens per session (1,888 once invoked), scanned A, original, MIT.

A focused security review of the current code change. It examines the branch difference from the base branch rather than auditing the entire project.

In plain words
What is it for?
It checks changed lines for leaked secrets, injection, server-side request forgery, broken access control, unsafe deserialization, and vulnerable or newly added dependencies.
Why use it?
It helps find concrete security problems introduced by the change without mixing them with general style or architecture feedback.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: installed under .agents/ (shared by several agents).

Part of the klaussy plugin — 79 skills, 3 hooks, 1 MCP server shipped together

Good fit It checks changed lines for leaked secrets, injection, server-side request forgery, broken access control, unsafe deserialization, and vulnerable or newly added dependencies.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/steph-dove/klaussy-agents/fastapi-security-audit
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.

Any agent
npx skills add steph-dove/klaussy-agents --skill fastapi-security-audit
Clone the repo
git clone --depth 1 https://github.com/steph-dove/klaussy-agents

Made for: Claude Code.

Or install klaussy, the plugin that ships this one along with the rest of its 79 skills, 3 hooks, 1 MCP server.

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 fastapi-security-audit

README.md
[![agentmods](https://agentmods.dev/badge/skills/steph-dove/klaussy-agents/fastapi-security-audit/github.svg)](https://agentmods.dev/skills/steph-dove/klaussy-agents/fastapi-security-audit)
Your own site
<a href="https://agentmods.dev/skills/steph-dove/klaussy-agents/fastapi-security-audit"><img src="https://agentmods.dev/badge/skills/steph-dove/klaussy-agents/fastapi-security-audit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for fastapi-security-audit

Your own site · 80×15
<a href="https://agentmods.dev/skills/steph-dove/klaussy-agents/fastapi-security-audit"><img src="https://agentmods.dev/badge/skills/steph-dove/klaussy-agents/fastapi-security-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,888 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.01888
Opus 5 $0.00000 $0.00944
Sonnet 5 $0.00000 $0.00378
Haiku 4.5 $0.00000 $0.00189

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

Security

Grade A, and why

fastapi-security-audit 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 10d 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.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

examples/fastapi/.agents/skills/fastapi-security-audit/SKILL.md · 71 lines

How it starts

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

You are running a security audit of the current change. Scope is the diff against the base branch and the immediate context of what it touches — not the whole tree, and not style or architecture. Report findings only; do not edit code.

If master is missing or unset, default to dev if it exists, otherwise main. Read the change with git diff master...HEAD first.

Lenses

Apply each lens to the ADDED and changed lines. A finding must point to a concrete line, not a general worry.

1. Secrets & credentials (Severity: High)

  • API keys, tokens, passwords, private keys, connection strings with embedded credentials, or high-entropy literals that look like real secrets in added lines. Obvious placeholders (YOUR_API_KEY, xxx, changeme) are not findings.

2. Injection & untrusted input (Severity: High)

  • SQL/NoSQL built by string concatenation or f-strings from request input instead of parameterized queries.
  • Shell execution from untrusted input (shell=True, string-built commands, eval/exec).
  • Command, path-traversal, template, or header injection where user input reaches a sink unsanitized.

3. SSRF & outbound requests (Severity: High)

  • A request URL, host, or port derived from user input without an allowlist — especially fetches that could reach internal addresses or metadata endpoints.

4. Access control & authn/authz (Severity: High)

  • A new endpoint, handler, or operation that skips the auth/permission check its peers apply.
  • Authorization decided on client-supplied data (role/owner from the request body), missing object-level ownership checks (IDOR), or a check that's logged but not enforced.

5. Unsafe deserialization & data handling (Severity: High)

  • pickle, yaml.load (non-safe), eval-based parsing, or native deserialization of untrusted bytes.
  • Disabled TLS verification (verify=False), weak crypto/hashing for security purposes (MD5/SHA1 for passwords, hardcoded IVs).

6. Dependencies (Severity: Medium unless a known CVE → High)

  • New dependencies added in this diff (manifest or lockfile). For each, ask: is it necessary, maintained, and from a trusted source? Flag typosquat-looking names and duplicates of a library already vendored.
  • Pinned-to-vulnerable or wildcard version ranges introduced by the change.

Read the full file on GitHub · 71 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. 10d ago First seen · 71 lines · 0 tokens per session scan A c34b02f21021

Subscribe to this mod's changes

fastapi-security-audit is a skill published in the GitHub repository steph-dove/klaussy-agents (16 stars, last pushed 14d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,888 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.