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.
npx agentmods add rules/coldtatooine/vuln-skill-pack/nextjs-vercel-securitygit clone --depth 1 https://github.com/coldtatooine/vuln-skill-packWrote 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.
[](https://agentmods.dev/rules/coldtatooine/vuln-skill-pack/nextjs-vercel-security)<a href="https://agentmods.dev/rules/coldtatooine/vuln-skill-pack/nextjs-vercel-security"><img src="https://agentmods.dev/badge/rules/coldtatooine/vuln-skill-pack/nextjs-vercel-security.svg" alt="Measured on agentmods" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00583 |
| Opus 5 | $0.00000 | $0.00292 |
| Sonnet 5 | $0.00000 | $0.00117 |
| Haiku 4.5 | $0.00000 | $0.00058 |
Grade B, and why
nextjs-vercel-security 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 6d 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.
- Server-side `fetch()` with a user-supplied URL → SSRF into internal services / cloud metadata (`169.254.169.254`). Allowlist hosts. Downgraded: this mod is about security review, or the phrase is quoted, so it is likely naming the pattern rather than instructing it.
How it starts
The opening of the file, as written. The whole thing — 35 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Next.js & Vercel Security Footguns
1. Secret leakage across the client/server boundary
NEXT_PUBLIC_*is public — inlined into the browser bundle. A real secret here is leaked. Only publishable/anon keys belong there.- Server-only secrets must never be imported into a Client Component. A module imported by a
"use client"file (directly or transitively) ships to the browser. Check import chains, not just the file. Useimport 'server-only'to fail the build if server code reaches the client. - Supabase
service_role, Stripesk_*, DB URLs → server only.
2. Server Actions
- Every Server Action is a public POST endpoint. No auth is applied automatically. Each must independently verify session AND authorization — do not assume it's only callable from your UI.
- Validate and authorize arguments. Args are attacker-controlled. Re-check ownership/tenant on every ID passed in. Don't trust hidden form fields.
3. Route Handlers (route.ts) & API routes
- No built-in auth — each handler checks session + role itself.
- IDOR:
/api/orders/[id]must verify the caller owns the order, not just that they're logged in. - Validate body/params before use; don't reflect errors verbatim.
4. Middleware auth bypass
middleware.tsmatchergaps let routes slip past auth. Verify the matcher covers every protected path (nested routes,/api, static).- Middleware is a filter, not the gate — re-enforce authz at the data layer. Never rely solely on a cookie's presence; verify the session/token signature.
5. SSRF & untrusted fetches
- Server-side
fetch()with a user-supplied URL → SSRF into internal services / cloud metadata (169.254.169.254). Allowlist hosts. - Image Optimization
remotePatterns/domainstoo broad can proxy arbitrary hosts.
6. Other
- Open redirect:
redirect(userInput)/?next=without validating it's a same-origin relative path. dangerouslySetInnerHTML: XSS if fed unsanitized input.- Caching: don't cache authenticated responses at the CDN/edge where another user could receive them.
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.
- 6d ago First seen · 35 lines · 0 tokens per session scan B 0e987f2df7c0
nextjs-vercel-security is a cursor rule published in the GitHub repository coldtatooine/vuln-skill-pack (2 stars, last pushed 11d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 583 tokens. 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-08-31.
Other cursor rules, from other repositories
pages
Source: docs/agents/pages.md Regenerate: npm run agents:sync -w packages/openbridge-webcomponents -->.
shadcn-tailwind-guide
本规范定义了使用 shadcn/ui 和 Tailwind CSS 开发新组件的标准流程和最佳实践。.
css-render-blocking-diagnosis
Cursor rule "css-render-blocking-diagnosis" from adobecom/da-express-milo, covering css render-blocking diagnosis & resolution, critical learning from 98 pagespeed achievement, primary diagnostic protocol, step 1: css blocking symptom recognition and step 2: css loading sequence audit.
frontend-architecture
Vite + React SPA architecture - directory layout, providers, bundle splitting. Tailwind styling in tailwind.mdc.
web-pages-e2e-test-maintenance
Keep web pages end-to-end coverage current.
tanstack-react-router_routing
TanStack Router: Routing.