# Next.js: Server-Side Request Forgery in rewrites via attacker-controlled destination hostname

Advisory record · `GHSA-p9j2-gv94-2wf4`

- **Identifiers:** `GHSA-p9j2-gv94-2wf4` · `CVE-2026-64645`
- **State:** Confirmed
- **Severity:** CVSS 8.3 High
- **Critical:** No
- **Weakness (CWE):** [CWE-601](https://cwe.mitre.org/data/definitions/601.html) · [CWE-918](https://cwe.mitre.org/data/definitions/918.html)
- **Tags:** [Open redirect](https://agentprime.io/advisories/tag/open-redirect.md) · [Server-side request forgery (SSRF)](https://agentprime.io/advisories/tag/ssrf.md)
- **Published:** 22 Jul 2026
- **Updated:** 10 Sept 2026
- **Reviewed by a person:** No

Published by the GitHub Advisory Database at 22 Jul 2026, 23:02 UTC. agentprime has not analysed this yet, so whether it affects any app is not known.

## Affected packages

- `next` (npm): affected `>=12.0.0, <15.5.21 || >=16.0.0, <16.2.11`; fixed in `15.5.21`, `16.2.11`

## Not analysed yet

We haven’t published our analysis of this Advisory yet. Once a person has reviewed it, this page will say what’s vulnerable, what has to be true for your app to be affected, and how to check.

## Severity and exploitation

- 8.3 High, CVSS 4.0: `CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:L/VA:N/SC:L/SI:L/SA:N`, from CNA (GitHub_M)

- **CISA KEV:** Not listed.
- **EPSS:** 0.0046, the 40th percentile, on 12 Nov 2026: FIRST’s estimate of the chance of exploitation in the next 30 days.

## Timeline

- 21 Jul 2026, 16:02 UTC: [Published by the maintainers as a GitHub repository advisory](https://github.com/vercel/next.js/security/advisories/GHSA-p9j2-gv94-2wf4)

## Sources

- [GitHub Advisory Database: GHSA-p9j2-gv94-2wf4](https://github.com/advisories/GHSA-p9j2-gv94-2wf4)
- [OSV: GHSA-p9j2-gv94-2wf4](https://osv.dev/vulnerability/GHSA-p9j2-gv94-2wf4)
- <https://github.com/vercel/next.js/security/advisories/GHSA-p9j2-gv94-2wf4>
- <https://github.com/vercel/next.js/commit/35f501357e9b0fe7c950b0d6aa8fcf5343f707e9>
- <https://github.com/vercel/next.js/commit/d3033266c6dff23f7be71e19341fe3a8c6e2c599>
- <https://github.com/vercel/next.js>
- <https://github.com/vercel/next.js/releases/tag/v15.5.21>
- <https://github.com/vercel/next.js/releases/tag/v16.2.11>

Facts on this page come from the GitHub Advisory Database (CC-BY 4.0), OSV and the other sources listed, as published. We don’t reproduce full advisory descriptions, which can contain exploit code.

## Check whether this affects you

A Match means an installed version is in the affected range above. Most don’t affect the app; agentprime hasn’t analysed this one yet.

- With the agentprime MCP server (<https://api.agentprime.io/mcp>), ask your agent to check the project: `check_lockfile` sends a lockfile, `check_packages` a list of installed packages, and both return the Matches and the upgrades that clear them. `get_advisory` returns this record. Setup: <https://agentprime.io/mcp.md>
- In a browser: <https://agentprime.io/check/> reads your lockfile in the browser, never uploading it.
- Whether it touches your code, with file and line: the Claude Code plugin, <https://agentprime.io/plugin.md>
- As JSON: <https://api.agentprime.io/v1/advisories/GHSA-p9j2-gv94-2wf4>, or `POST https://api.agentprime.io/v1/match` with your packages (<https://agentprime.io/api.md>)

---

The web page: <https://agentprime.io/advisories/GHSA-p9j2-gv94-2wf4/>. Everything for agents: <https://agentprime.io/llms.txt>.
