security-audit

security-audit is a skill for Claude Code from PostHog/posthog-foss. It costs 179 tokens per session (9,316 once invoked), scanned B, original, MIT.

A code-security review guide focused on finding vulnerabilities that an attacker could actually exploit. It traces user-controlled data through the code to risky operations such as database queries, shell commands, or file access.

In plain words
What is it for?
Use it to audit files, directories, branch changes, pull requests, or specific features for exploitable security bugs.
Why use it?
It reduces security reviews filled with theoretical warnings or style advice by concentrating on demonstrable problems. It helps uncover issues such as broken access control, IDOR, SSRF, XSS, and injection when supported by the code.

Skill for Claude Code

Written for Claude Code: $ARGUMENTS substitution. Also seen: installed under .agents/ (shared by several agents).

Good fit Use it to audit files, directories, branch changes, pull requests, or specific features for exploitable security bugs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/posthog/posthog-foss/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 PostHog/posthog-foss --skill security-audit
Clone the repo
git clone --depth 1 https://github.com/PostHog/posthog-foss

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/posthog/posthog-foss/security-audit/github.svg)](https://agentmods.dev/skills/posthog/posthog-foss/security-audit)
Your own site
<a href="https://agentmods.dev/skills/posthog/posthog-foss/security-audit"><img src="https://agentmods.dev/badge/skills/posthog/posthog-foss/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 security-audit

Your own site · 80×15
<a href="https://agentmods.dev/skills/posthog/posthog-foss/security-audit"><img src="https://agentmods.dev/badge/skills/posthog/posthog-foss/security-audit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 179 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 9,316 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 2 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Server-Side Request Forgery · line 73
    Code accesses a cloud instance metadata endpoint (e.g. 169.254.169.254). A single request can return temporary IAM credentials, making this a high-value SSRF target for credential theft.
    Fix: Remove access to cloud metadata endpoints unless strictly required. If metadata is needed, restrict it (e.g. IMDSv2 with hop limit) and never expose returned credentials.
  • medium Rogue Agent · line 75
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
How audits are shown
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.00179 $0.09316
Opus 5.5 $0.00072 $0.03726
Sonnet 5.5 $0.00036 $0.01863
Haiku 4.5 $0.00018 $0.00932

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

Security

Grade B, and why

security-audit scanned grade B with 1 finding 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 24d 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.

Cloud metadata endpointmediumServer-side request forgery

One request to 169.254.169.254 can return temporary IAM credentials.

- SSRF: outbound HTTP to user-supplied URLs without an allowlist. Watch for follow-redirects, DNS rebinding, and access to localhost / cloud metadata IPs / `metadata.google.internal`. Check both `requests` and any custom

Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.

.agents/skills/security-audit/SKILL.md · 402 lines

How it starts

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

Security Audit

You are a senior application security engineer. You audit a change for exploitable vulnerabilities. You build a threat model for the change first. Then you assess the implementation against that model.

This order matters. A threat model names the assets, the entry points, and the attackers for this specific change. A checklist scan does not. The model finds the real bugs that a scan misses.

Report real, demonstrable bugs only. Do not report theoretical concerns, best-practice nudges, or style nits.

Use extended thinking throughout. Read the code before you report.

Input

Audit target: $ARGUMENTS

Resolve the target as follows:

  • Empty: audit the current branch's diff against the main branch (git diff $(git merge-base HEAD origin/main 2>/dev/null || git merge-base HEAD main)...HEAD).
  • branch: same as above.
  • A PR number or URL: gh pr view <ref> --json title,body,commits,files and gh pr diff <ref> for the diff and context.
  • A file or directory path: read it directly and audit its contents.
  • A free-form description (e.g., "the new webhook handler"): grep/glob to locate the relevant files, then audit those.

If the target is ambiguous, state your interpretation at the top of the report and proceed.

Gather context

The threat model is only as good as your understanding of the change.

  • Understand the purpose of the change from a product standpoint. Learn what user problem it solves, who calls the new surface, and what data flows through it.
  • Read the linked issues, and any Slack threads or extra context the user gives you. Use the Slack MCP for Slack links.
  • Read the surrounding code, not just the diff. Read the callers, the auth decorators, the serializers, and the existing mitigations. A diff-only review misses how the change is reachable.
  • Repo mode: when the target is a whole repo, threat model the application architecture first (deployment target, auth layers, data stores), then assess the implementation. Infer the deployment context from the code. Ask the user only when you cannot infer it.

Read the full file on GitHub · 402 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. 24d ago Changed 877655ba53d9
  2. 1mo ago Changed · +117 lines · +55 tokens per session 9319a7e13b70
  3. 1mo ago Changed 5b1c271b5139
  4. 1mo ago Changed fec289e695d9
  5. 1mo ago Changed · +1 lines b965a6517bd8
  6. 3mo ago First seen · 284 lines · 124 tokens per session scan B c3746ad08448

Subscribe to this mod's changes

security-audit is a skill published in the GitHub repository PostHog/posthog-foss (736 stars, last pushed today), licensed MIT. It adds 179 tokens to every session and 9,316 once invoked, about $0.0007 per session on Opus 5.5. A static security scan graded it B with 1 finding (cloud metadata endpoint). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

security-audit compared with skills from other repositories

security-audit next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
security-auditPostHog/posthog-fossSkill736todayMITB179Claude Code
local-ai-agentsmicrosoft/ai-agents-for-beginnersSkill82ktodayMITA200Claude Code, Codex
imagegenopenai/codexSkill137ktodayApache-2.0A113Codex
playwright-climicrosoft/playwrightSkill102ktodayApache-2.0A19Claude Code
browser-automationopenclaw/openclawSkill396ktodayMITA36Claude Code
free-llm-apismnfst/awesome-free-llm-apisSkill15ktodayCC0-1.0A113Claude Code, Codex
systematic-debuggingobra/superpowersSkill333k7d agoMITA21Claude Code