agentleFS
hamzaciftcihamzaciftci/coding-orchestra/skills/security-audit/SKILL.md

security-audit

Skill0 starsChanged 38 days agoMITView on GitHub

Audits a web application the user owns for exploitable vulnerabilities and fixes them, with depth on Next.js, serverless, Supabase, Prisma and Stripe failure modes such as IDOR, unauthenticated Server Actions, unsigned webhooks, open cron routes and leaked keys. Use when the user asks for a security audit or review, asks whether an app is safe to launch, wants vulnerabilities found or closed, or is responding to a suspected leak or breach.

192 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use create-stories, story-done and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • lilangMaxSkill

    create-stories

    Break a single epic into implementable story files. Reads the epic, its GDD, governing ADRs, and control manifest. Each story embeds its GDD requirement TR-ID, ADR guidance, acceptance criteria, story type, and test evidence path. Run after /create-epics for each epic.

    Also in 11 projects that use this

  • lilangMaxSkill

    story-done

    End-of-story completion review. Reads the story file, verifies each acceptance criterion against the implementation, checks for GDD/ADR deviations, prompts code review, updates story status to Complete, and surfaces the next ready story from the sprint.

    Also in 11 projects that use this

  • nicepkgSkill

    community-led-growth

    Expert in community-led growth (CLG) - leveraging user communities to drive acquisition, retention, and expansion. Covers building developer communities, user groups, ambassador programs, and turning customers into advocates. Knows the difference between community as a feature vs community as a growth engine, and how to measure community ROI. Use when "community-led, CLG, ambassador program, champion program, user community, developer community, word of mouth, user group, " mentioned.

    Also in 5 projects that use this

  • nicepkgSkill

    ph-community-outreach

    Engage Reddit, Indie Hackers, Hacker News and other communities for Product Hunt launches. Use this skill to identify relevant communities, craft appropriate posts, and drive cross-platform engagement without appearing spammy.

    Also in 5 projects that use this

  • +7 more from lilangMax
  • +1 more from nicepkg

The file

We split this skill into the rules it gives an agent

2 rules. 0 are common, 1 is distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 173 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Map the surface first: Run the inventory script from this skill's directory against the project:

    line 24
  2. Very specific:

    Read references/stack-pitfalls.md before judging any area clean.

    line 36

“Common” is measured: kept by at least 6 in 10 of the 173 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Security audit

This is defensive work on code the user owns or is authorized to assess, which in practice means the repository in front of you and its local or test environment. Describe how a flaw could be abused in enough detail to justify its severity and to verify the fix. Do not write weaponized exploits or scanners, and do not probe hosts the user does not control. If part of a request targets someone else's system, decline that part and continue with the rest.

What a good audit delivers

  • A complete map of what can be reached from outside, so nothing is missed because nobody looked.
  • Findings that each point at a code path. A reader should be able to open the file and see the problem.
  • Fixes for what the user asked to have fixed, each verified.
  • An honest account of what was not checked and what only the user can do.

Approach

Map the surface first. Run the inventory script from this skill's directory against the project:

node scripts/attack-surface.mjs <project-dir>

It lists route handlers, Pages API routes, Server Actions, the middleware matcher and vercel.json crons with text signals for auth, validation and risky sinks, then tables found in SQL files with their row level security state, and code patterns worth a look. The output tells you where to read; it is not a list of findings, and a clean line proves nothing. Add what the script cannot see: policies set in a dashboard, storage buckets, edge functions, third-party callbacks.

Then read each entry point and answer three questions: who can call this, what do they control, and what does it touch. Follow the caller's identity from the request all the way into the query, including the helper that produces the session: if that helper is wrong, every route that relies on it is wrong. Most serious findings in this stack are a missing link in that chain, and they look fine at a glance.

Then sweep what does not live in an entry point: how sessions and cookies are issued, password storage, rendering of stored content, CORS and security headers, what reaches the client bundle, database policies, error responses, and framework and dependency versions. Before writing the report, go back over the script output and check that every route, action, table and pattern line was either reported or deliberately cleared.

Read references/stack-pitfalls.md before judging any area clean. It lists the failure modes specific to Next.js, serverless platforms, Supabase, Prisma and Stripe that generic checklists miss.

Audit or fix? If the user asked for an audit, report and change nothing. If they asked to find and fix, apply contained fixes directly (a missing ownership filter, a signature check, an input schema) and stop for approval before changes that alter behaviour for legitimate users or cannot be undone: auth flows, app-wide CORS, CSP or cookie settings, database policies and schema, anything that needs a secret rotated or git history rewritten.

Verify every fix with a test or a concrete request sequence that shows the unauthorized path now fails and the legitimate path still works. If you could not run it, say so; do not describe an unrun check as passed.

Judgment calls that matter

  • Leaked secrets. Removing a secret from the code does not fix a leak. The secret has to be rotated, and only the user can do that. Report it by variable name and location, never by value, and do not open real env files to confirm it. Rewriting git history is destructive and is the user's decision.
  • Only report what you can point to. "Nothing found" is a valid result for a category. Mark each finding Confirmed (traced in code) or Needs verification (depends on something outside the repo, such as dashboard policies or platform env values) so the reader knows which is which.
  • Severity follows what an attacker gains and what they need. Critical: an anonymous or any logged-in user reaches other users' data, money, admin functions or a secret. High: the same with meaningful preconditions. Medium: limited impact or unlikely preconditions. Low: hardening.
  • Never switch a control off to test something, and never leave a bypass in place.
  • A fix can break the app. Tightening CORS, CSP or cookie flags changes behaviour everywhere; check what depends on the current behaviour first.

Report

Lead with a summary table, most severe first, then one block per finding with the eight fields in references/report-template.md: what, severity and why, location, how it could be abused, the fix, why that closes it, residual risk, and how to verify. Finish with what was out of scope or unverified, and the actions only the user can take.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.