secure-impl
Skill0 starsChanged 50 days agoMITView on GitHub
Applies security-by-default rules while implementing or modifying application code — file uploads, auth and per-user data access, API keys and env vars, paid/metered API calls, usage quotas, billing state, error handling, and LLM/agent features. Triggers proactively on any feature that accepts user input, stores user-owned data, checks permissions, spends money per request, or feeds untrusted content to a model — even when the request never mentions security. Also triggers on Chinese-language requests about 上傳、登入、權限、額度、金鑰、資安、串接 API.
1 other project uses a version of this.
Adopted by
Most recently taken up by
- usio0108/security-shipping-gatesword for word, first seen Nov 1, 2026
Other versions1 project uses a version of this.
Word for word · 1
- usio0108/security-shipping-gates★ 0100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository2 other files it gives its agents.
- dep-vettingSkill
- preflight-auditSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
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
- Distinctive: line 26
Read only the file that matches what is being built — the other four don't apply here and just cost context for nothing.
- Very specific: line 57
If the work touched auth, per-user data, or spending, recommend the preflight-audit skill before deploying.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Secure webapp implementation
Working code and safe code are different targets. A feature can pass every manual test and still hand an attacker the database, because the failure is in where a check runs or who is trusted, not in whether the code executes. Nothing in this skill is exotic; the common failures are ordinary and repetitive.
Apply these rules while writing the code. Retrofitting them after launch means rewriting the data model.
The five rules that cover most of it
- Data you never collect can never leak from you. Before adding a field or an upload, ask whether the product actually needs to hold it, or whether the work can happen on the user's machine. Extract audio client-side instead of uploading whole videos; read local fonts instead of storing them; render output in the browser instead of on your disk.
- The client can only hide things. Only the server can forbid them. Every rule enforced in the UI — plan limits, file length caps, admin-only buttons — is running on the user's computer and is editable by them. They can also skip your UI entirely and call the endpoint directly. Duplicate every limit server-side.
- Authentication is not authorization. Knowing who someone is says nothing about what they may touch. Most real breaches are a logged-in user reaching another user's row by changing an ID. Every query that returns or mutates user-owned data must be scoped to the caller's identity.
- Never trust a value from the browser for anything involving money or privilege. Price, plan tier, remaining quota, role, and payment status are server-derived facts. Look them up by ID server-side; do not accept them as request parameters.
- Assume a key will leak and an account will be taken over. Design so the answer to "what could they reach?" is small: least privilege, per-row database rules, separate dev/prod credentials, human confirmation on destructive or outbound actions.
Route to the relevant reference
Read only the file that matches what is being built — the other four don't apply here and just cost context for nothing.
| Building this | Read |
| File upload, media ingest, anything accepting user files | references/uploads.md |
| Login, sessions, per-user data, multi-tenant tables, RLS policies | references/auth-and-authz.md |
| Env vars, API keys, anything about to be committed or deployed | references/secrets.md |
| Calls that cost money per request, quotas, free credits, plan tiers | references/cost-and-quota.md |
| Chatbots, summarizers, translation, any agent reading user content | references/ai-features.md |
When the user asks for a limit, ask where it runs
Requests like "free users get 5 transcriptions a day" or "cap uploads at 10 minutes" are ambiguous by default. Implement them server-side, and say so explicitly in the response. If a UI-side check is also added for user experience, state plainly that it is cosmetic and the server check is the real one. Silently writing the limit in the frontend is the single most common way this goes wrong.
Production error handling
Development builds print stack traces, SQL, and internal paths. Shipping that to strangers hands over a map of the system. In production, return a generic message to the client and log the detail server-side. Also remove or password-protect any debug/test routes created during development — they usually survive to production untouched.
What to tell the user when finishing a feature
Close every feature's summary with exactly this template, fields in this order:
Server-side checks: <what runs on the server and cannot be bypassed from the client>
Client-side checks: <what runs in the UI only — cosmetic, not a security boundary>
Blast radius: <what an attacker could reach if this feature's credentials leaked>
Unverified: <the one thing that still needs a manual test before this is trusted>A fixed template makes the summary scannable and makes an empty or skipped field obvious — do not paraphrase the field names or drop a field because it seems obvious in context.
If the work touched auth, per-user data, or spending, recommend the preflight-audit skill before deploying.
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
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.

