nextjs-vercel-security

nextjs-vercel-security is a skill for Claude Code from coldtatooine/vuln-skill-pack. It costs 56 tokens per session (967 once invoked), scanned B, original, MIT.

A security review guide for Next.js applications and projects deployed on Vercel. It covers common mistakes involving secrets, login checks, server endpoints, and cached responses.

In plain words
What is it for?
Use it when reviewing, building, or deploying a Next.js or Vercel project to check secret exposure, missing access checks, request-forgery risks, server-side request forgery, and unsafe caching.
Why use it?
It helps reviewers distinguish real security problems from safe patterns, such as public browser keys or intentionally public POST endpoints.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the vun-skill-pack plugin — 5 skills, 11 commands, 1 agent, 1 hook shipped together

Good fit Use it when reviewing, building, or deploying a Next.js or Vercel project to check secret exposure, missing access checks, request-forgery risks, server-side request forgery, and unsafe caching.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security
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 coldtatooine/vuln-skill-pack --skill nextjs-vercel-security
Clone the repo
git clone --depth 1 https://github.com/coldtatooine/vuln-skill-pack

Made for: Claude Code.

Or install vun-skill-pack, the plugin that ships this one along with the rest of its 5 skills, 11 commands, 1 agent, 1 hook.

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 nextjs-vercel-security

README.md
[![agentmods](https://agentmods.dev/badge/skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security/github.svg)](https://agentmods.dev/skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security)
Your own site
<a href="https://agentmods.dev/skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security"><img src="https://agentmods.dev/badge/skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security/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 nextjs-vercel-security

Your own site · 80×15
<a href="https://agentmods.dev/skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security"><img src="https://agentmods.dev/badge/skills/coldtatooine/vuln-skill-pack/nextjs-vercel-security.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 56 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 967 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.
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.00056 $0.00967
Opus 5 $0.00028 $0.00483
Sonnet 5 $0.00011 $0.00193
Haiku 4.5 $0.00006 $0.00097

Measured 9d ago against content hash 1036d5bc8d47, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

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 9d 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.

skills/nextjs-vercel-security/SKILL.md · 64 lines

How it starts

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

Next.js & Vercel Security Footguns

Apply this when the codebase uses Next.js (App or Pages Router) or deploys to Vercel. These are the high-frequency holes; pair with /scan, /preflight, and /secrets.

Verify before flagging

  • NEXT_PUBLIC_* with publishable/anon/pk_ keys is expected — only flag real secrets (service_role, sk_, DB URLs, JWT secrets).
  • Middleware matcher gaps need a concrete uncovered protected path, not a vague "matcher looks incomplete."
  • A Server Action that verifies session + ownership is not "unauthenticated" just because it is a public POST endpoint by design.
  • CDN/edge caching is only a finding when authenticated or user-specific responses can be cached and shared.

1. Secret leakage across the client/server boundary

  • NEXT_PUBLIC_* is public. Anything with this prefix is inlined into the JS bundle and shipped to the browser. A real secret here = leaked secret. Only publishable/anon keys belong here.
  • 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.
  • server-only package: server code that must never reach the client should import 'server-only' to fail the build if it does.
  • Supabase service_role, Stripe sk_*, DB URLs → server only.

2. Server Actions

  • Every Server Action is a public POST endpoint. No auth is applied automatically. Each action must independently verify session AND authorization — do not assume it's only callable from your UI.
  • Origin / CSRF posture: confirm actions check a trusted origin (or equivalent framework protection) and a valid session before mutating state.
  • Validate and authorize arguments. Args are attacker-controlled. Re-check ownership/tenant on every ID passed in. Don't trust hidden form fields.
  • Actions defined inline in a Server Component are still individually invocable.

3. Route Handlers (route.ts) & API routes

Read the full file on GitHub · 64 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. 9d ago First seen · 64 lines · 0 tokens per session scan B 1036d5bc8d47

Subscribe to this mod's changes

nextjs-vercel-security is a skill published in the GitHub repository coldtatooine/vuln-skill-pack (2 stars, last pushed 15d ago), licensed MIT. It adds 56 tokens to every session and 967 once invoked, about $0.0003 per session on Opus 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-08-31.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

insight-error-page

Write or audit an insight-kind error page for the Next.js dev overlay. Use when creating a new errors/ .mdx page, auditing an existing one, or checking that a page matches the framework fix cards. Covers page structure, title alignment, FixCard cards with Copy prompt button, code snippets, terminology verification…

vercel/next.js · 83 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens