/nightvision:chain-attacksfrom nightvision
Find and reproduce multi-step business-logic vulnerabilities (vuln chains) in a web app or API, where each request is individually allowed but the ordered combination across steps or sessions breaks a business rule. Use after adding a multi-step flow (checkout, invite/accept, approval/publish, password reset, refund), when a user asks "can a sequence of allowed requests reach a forbidden state", to test business-logic or chained vulnerabilities, or as part of ship-check. Non-destructive and dev-only: it never takes a state-changing action and runs only against an app the developer owns.
Ships in nightvision. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Scanners and humans both struggle with the same bug: a flaw where every single request is allowed, but the ordered combination of requests, sometimes across two sessions, reaches a state the business rules forbid. You cannot find it one request at a time. It takes holding a hypothesis across many requests and reading each response to shape the next one: mint a token in tenant A's flow and spend it in tenant B's session, mark an order shipped without ever paying, replay a one-time reset token, let a price set in step one be trusted by step five. This skill builds a model of the app, derives those hypotheses from a fixed taxonomy, and runs each one as a scripted ordered sequence with a legitimate-actor control, so a chain is reported only when it actually reproduces.
Relationship to authz-review. authz-review asks "can user B touch user A's object in one request": single-request, object-level and function-level access control. chain-attacks asks the harder question: "can a sequence of individually-allowed requests, possibly across two sessions, reach a state the business rules forbid." It reuses the actor and object model authz-review builds and goes beyond it to sequences, state machines, and values that flow from one step into the next. Run authz-review first; its single-request gaps are the cheaper find, and its model is the starting point here.
What this is and is not: it is a code review plus ordered, non-destructive probes run against an environment the developer owns. It is not a NightVision scan result. Report what you find as CODE REVIEW findings, never as NightVision findings, and never claim a flow is safe because this skill did not flag it.
Portability. The executable core is just Bash, curl, and reading source files, so it runs on any agent and any model (Codex included), with no dependency on the NightVision MCP tools or any Claude-only feature. The allowed-tools line lists the NightVision read tools, but every step works without them: they are optional enrichment for an agent that has the NightVision MCP wired up, never a requirement. Lead with the portable path everywhere (an OpenAPI spec from the nightvision openapi extract CLI, or reading routers and controllers directly).
Never perform a destructive or state-changing action to prove a chain. No refund, no delete, no role grant, no publish, no status change, no money movement, no token consumption, not even against data the agent seeded itself. There is no exception for "it is only my own test data": the point of this skill is to prove reachability safely, and a half-run chain that already moved money is not a cleaner result than one stopped one step short.
Reads are fine. Safe idempotent probes that do not change state are fine (a GET that reveals whether an authorization check passes, re-fetching a token's status, reading the current state of an object). Creating throwaway data is the developer's call to describe in their own setup, not the agent's to do on its own initiative.
This binds the control run too. The benign baseline exists to show how the app behaves when used correctly, not to license a destructive action because it is "the intended one." Establish it by reading developer-seeded state wherever you can. Any benign step you do run must itself be non-destructive: no money movement, no deletion, no role or permission grant, no publish or fulfillment, no outbound send of real data. When the benign path's completion would require one of those, read a developer-seeded example that already reached that state instead of performing it.
When a chain can only be confirmed by taking a state-changing action, stop one step short and report it as "reachable, not executed." Give:
A "reachable, not executed" finding is a real finding. It is reported with the same weight as a reproduced one; the only difference is the last request is left for the developer to send in their own environment if they want the final confirmation.
owner_id, tenant_id, org_id), so you know what "belongs to A" means.nightvision openapi extract (which writes openapi-spec.yml, every operation with its source file:line), or read the routers and controllers directly, or generate a spec with the source-intelligence skill. If your agent has the NightVision MCP wired up, the read-only tools in allowed-tools (list-targets, get-scan-paths, list-issues, and the rest) can enrich the model, but nothing here requires them. Reuse authz-review's actor/object work rather than redoing it.references/attack-taxonomy.md and write down every candidate: which flow, which class, and the exact ordered sequence you would run. Do not invent classes; the taxonomy is the checklist.references/attack-taxonomy.md.Six classes, each a named subsection in references/attack-taxonomy.md with what it is, how to recognize candidate flows from the model, and the exact ordered test:
The reference file carries the detailed recipe for each, and repeats the non-destructive stop-short handling on the classes that would otherwise tempt a state change (refund replay, role grant, delete-based proofs). Read it before running step 2.
Report CODE REVIEW findings. For each reproduced or reachable chain:
Chain: <short name> (<taxonomy class>)
Target: <host> (confirmed dev/local, owned by developer)
Flow: <the business flow and the rule it breaks>
Status: REPRODUCED | REACHABLE, NOT EXECUTED (stopped before <state change>)
Control run (benign path, as <intended actor>):
1. <METHOD> <path> [session: <actor>] -> <status>, <proving field>=<value>
...
Result: <what the benign path correctly does>
Attack run (as <attacker sessions>):
1. <METHOD> <path> [session: <actor>] -> <status>, <proving field>=<value>
2. <METHOD> <path> [session: <actor>] -> <status>, <proving field>=<value>
...
Result: <the forbidden state reached, or the exact next request NOT sent and why>
Evidence: <the response field(s) that prove it, and for reachable-not-executed, why the next step is reachable>
Code: <file:line of the missing check, if found>
List REPRODUCED chains first, then REACHABLE-NOT-EXECUTED. End with a one-line note of the classes you tried where the control matched the attack (no finding), so the developer knows what was covered.
authz-review covers single-request object-level and function-level access control and builds the actor/object model this skill reuses. secure-build covers the business-logic rules to follow while writing the code. ship-check runs this review as part of finishing an app. app-security-scan runs a NightVision DAST scan of the running app.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub nvsecurity/nightvision-mcp --plugin nightvision14 skills in this plugin
/api-discoveryFormer name of the source-intelligence skill, kept so that invoking api-discovery still works. Use source-intelligence instead./app-security-scanDAST-first NightVision scan for an app you just built or changed. Use when a user, or a project or org agent-instructions rule, wants a local, private, staging, or internal web app/API security-scanned. Drives the NightVision MCP `run-app-security-scan` harness./authz-reviewReview an app's object-level and function-level access control (BOLA/IDOR, broken function-level authorization, mass assignment) route by route, then write a two-user test the developer can run against their own local or dev app. Use after adding or changing routes that take object IDs, tenant or user identifiers, or admin-only actions, when a user asks "can one user see another user's data", or as part of ship-check./ci-cd-integrationGuide for agents to help users integrate NightVision DAST scanning into CI/CD pipelines. Use when setting up security scans in GitHub Actions, GitLab CI, Azure DevOps, Jenkins, BitBucket, or JFrog pipelines, configuring NightVision tokens, creating targets, running scans, exporting results as SARIF/CSV, or detecting API breaking changes./fleet-statusRead-only AppSec roll-up of every app in NightVision - which apps exist, when each was last scanned, and where the open Critical and High findings are. Use when a user asks "who is building what", wants scan posture across all apps, asks which apps have never been scanned or have stale scans, or needs an AppSec roll-up for a CISO. It starts no scans and changes nothing./multi-agent-relayStand up and drive multiple coordinating agents that build a feature through a filesystem relay: a driver that authors one task prompt at a time, an implementation agent (a standing poll-loop session OR a freshly spawned subagent) that implements and tests, and a shipping agent that commits, reviews, fixes, and ships - all coordinating through report files with a fixed status-line protocol and background monitors. Use when executing an approved multi-task sequence across one or more repos with separate agents that must stay in distinct lanes.