Omniscio

OmniscioSkills examplesSecurity audit

A Claude Code security audit skill you can copy

One complete SKILL.md for the security pass before a release, or after a new route appears. Anthropic's own scanning routes are covered by the Claude Security plugin page and the security guidance page; this is a checklist you own, run in your own session. The mechanism is in the skills guide.

Checked against Anthropic's documentation on November 25, 2026. By the Omniscio team. Updated .

When this skill fires

The description names a security review, a security audit, and the question of whether a change is safe to ship, because that is how the request arrives.

  • On its own when you ask "audit this for security", "is this endpoint safe", or "review the auth on this branch".
  • Directly with a path or a branch: /security-audit src/api, or /security-audit alone to audit what the branch changes.

Model invocation stays on, because the audit only reads. If it starts appearing on requests that merely mention security in passing, the last section has the two documented fixes.

The whole skill, ready to copy

Save this as SKILL.md inside a folder named security-audit, frontmatter first.

---
name: security-audit
description: Audits code for authorization gaps, unvalidated input, secrets and unsafe shell or SQL use, and reports every finding by severity with a file and line. Use when the user asks for a security review, a security audit, or whether a change is safe to ship.
argument-hint: [path-or-branch]
allowed-tools: Read Grep Glob Bash(git diff *) Bash(git status *)
---

Audit $ARGUMENTS. If it is a path, scope every check below to the files under it. If it is a branch name, audit `git diff ...`.

With no arguments, audit what this branch changes: run `git status --short`, then `git diff origin/main...HEAD`, substituting your default branch when it is not main. Say in the report which base and which uncommitted files you covered.

## Check these, in this order

1. Authorization: every entry point that reads or writes data establishes who the caller is before it acts, unless the route is deliberately public, in which case check that what it returns is genuinely public. A check in the interface is not a check.
2. Untrusted input: request bodies, query strings, headers, file names and anything from another service are validated at the boundary, and values are bound rather than concatenated into SQL or a shell command.
3. Secrets: keys and tokens stay out of logs, error messages, client bundles and the repository. A secret in a log line is a leaked secret.
4. Paths and URLs: a path built from input is resolved and checked against an allowed root, and an outbound address is checked before it is fetched.
5. Defaults: an unpinned new dependency with no lockfile entry, a wildcard permission, a permissive cross-origin rule or a debug flag left on is named as a finding, not a note.

## Report

One table, most severe first: severity, file:line, what an attacker could do, and the smallest fix. End with one line naming what you checked and found clean.

Severity means: critical is reachable now without credentials and gives up data or code execution; high needs a foothold or a crafted input but still crosses a trust boundary; medium needs an existing bug or a chain to matter; low is hygiene.

Rules:

- A finding without a file and a line is a guess. Drop it, unless it would change the release decision; then put `not verified` in the file:line column and say what would confirm it.
- Do not write exploit code and do not test against a running system.
- Do not cite a vulnerability database entry you have not read.
- Do not edit files. Propose the fix and let the user decide.

What each part does

Every field is optional, and only description is recommended. Names are matched exactly, hyphens included, and an unrecognised field is ignored without an error.

The four frontmatter fields in this file, and what each one changes.
FieldWhat it does here
name: security-auditThe command in the / menu, and the name to avoid changing: see the failure section
descriptionWhat the skill does and when to use it. This is the text Claude matches a request against, so it holds the words "security review" and "safe to ship"
argument-hint: [path-or-branch]The hint shown after the command name during autocomplete. Square brackets, not angle brackets, which display escaped in a description
allowed-tools: Read Grep Glob Bash(git diff *) Bash(git status *)Pre-approves reading, searching and the two git commands the body asks for, for the turn the skill runs. It grants no write, and it clears on your next message
  • The fixed order is the point. Authorization first, because a missing check makes every later finding worse; defaults last, because they are the easiest to argue about and the least likely to be urgent.
  • "What an attacker could do" turns a rule violation into a decision. "Missing validation" is a lecture; "this query string reaches a shell command" is a bug with a size.
  • "Drop it, or mark it as not verified" is the rule that keeps the report short enough to act on. An audit with thirty unverified findings is an audit nobody finishes.
  • "What you checked and found clean" is what tells a reader the audit covered the whole list rather than stopping at the first table.
  • "Do not write exploit code" keeps the skill inside a code review. Proving an issue is a separate, authorised exercise.

The body is under forty lines, well inside Anthropic's guidance of 500 lines, which matters because a loaded skill's content stays in the conversation and is paid for on every later turn.

Where to put it: personal or project

The same file, two locations, two audiences.
ChoosePathWho gets it
Personal~/.claude/skills/security-audit/SKILL.mdYou, in every project on this machine, but not Cowork or cloud sessions
Project.claude/skills/security-audit/SKILL.mdEveryone in this repository once it is committed, which is what a team with a security rule wants

If both exist, personal wins: enterprise beats personal and personal beats project. A repository's security checklist is worthless if a home-folder copy replaces it silently, so ship only one.

Claude Code watches both directories and picks up an added or edited skill within the session, except in bare mode; /reload-skills loads one that does not appear.

How to confirm it loads

  1. Find the command. Type / and look for security-audit, or open /skills.
  2. Run it on a route you know. Pick one endpoint and run /security-audit with its path. Every finding must carry a file and a line, or say it is not verified.
  3. Check the ending. The report should close with what was checked and found clean, which is the fastest way to see that it worked the whole list.
  4. Test the automatic route. Ask "is this endpoint safe to ship". If that does not load it, put those words into the description.

/doctor estimates the skill listing's context cost, and /skill-doctor reports what each skill costs and how often it is used.

The common failure

The name is the trap. Claude Code has a built-in /security-review command that checks the branch's diff against origin's default branch, and a skill of yours with that name replaces it in a local terminal session. If you name this file security-review to match the words you type, you lose a command you had and gain one that behaves differently at the same prompt.

  • If /security-review changed behaviour, a skill replaced it. Rename the folder and the name field to security-audit.
  • If it fires whenever the word security appears, Claude is matching too broadly. Anthropic's fixes, in order: make the description more specific, then add disable-model-invocation: true if you only want to run it by hand.
  • If the report is a list of general advice, the findings lost their file and line. The body tells it to drop or mark anything it cannot point at; if it still happens, tighten the scope argument to one folder.
  • If it wants to run the app to prove a finding, say no. The body forbids testing a running system, and an audit that starts sending requests is no longer a read-only review.

One silent trap sits above all of these: if the opening three dashes are not the file's first line, the frontmatter is treated as body text, and the skill runs when typed but never fires on its own.

Where this fits

This is the security pass, not the review. For correctness, tests and readability on the same change, use the review checklist skill; the built-in review routes and their costs are in the code review guide. For a deeper, multi-agent scan of an entire repository, that is the Claude Security plugin, which is a different tool with a different cost.

The rest of the library, including a test writer and a debugging runbook, is at the skills examples hub. What a skill is and the full frontmatter reference is the Claude Code skills guide.

Where these answers come from

  • Extend Claude with skills, read November 25, 2026: the folder and file, the frontmatter fields used here, allowed-tools, the bundled skills, name resolution, the content lifecycle and the troubleshooting sections.
  • Skill triggers too often: the two documented fixes for a skill that matches too broadly.
  • The commands reference, read November 25, 2026: the /security-review row, its origin-remote requirement and what it checks.
  • The changelog: release 2.1.332, dated November 25, 2026, the newest listed on the day this page was checked.

Common questions

Is this the same as the built-in /security-review?

No, and it is deliberately not named that way: see the common failure above. This is a checklist you own, in your own session, with your own severity definitions.

Does it replace a real security review?

No. It is a first pass that catches the mistakes a checklist catches: a missing authorization call, a value concatenated into a query, a secret in a log line. A security-critical change still needs a person who can think about the system.

Why does it refuse to test the running app?

Because sending requests at a live system turns a review into an attack, and you did not ask for that. The file is deliberately read-only; proving a finding is a separate decision.

Can it audit the whole repository?

It can be asked to, but the body defaults to the current branch's change, because a whole-repository audit is slow and mostly repeats what the previous audit said. Point it at one folder when you want depth.