# CVE-2026-27978: Next.js: null origin can bypass Server Actions CSRF checks

- Severity: Medium 5.3 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.23%, higher than 15% of CVEs (2026-12-01)
- Published: 2026-03-17T15:30:14.000Z
- Modified: 2026-06-17T10:28:00.450Z
- Also known as: GHSA-mq59-m269-xvcx
- Weaknesses: CWE-352
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Next.js is a React framework for building full-stack web applications. Starting in version 16.0.1 and prior to version 16.1.7, `origin: null` was treated as a "missing" origin during Server Action CSRF validation. As a result, requests from opaque contexts (such as sandboxed iframes) could bypass origin verification instead of being validated as cross-origin requests. An attacker could induce a victim browser to submit Server Actions from a sandboxed context, potentially executing state-changing actions with victim credentials (CSRF). This is fixed in version 16.1.7 by treating `'null'` as an explicit origin value and enforcing host/origin checks unless `'null'` is explicitly allowlisted in `experimental.serverActions.allowedOrigins`. If upgrading is not immediately possible, add CSRF tokens for sensitive Server Actions, prefer `SameSite=Strict` on sensitive auth cookies, and/or do not allow `'null'` in `serverActions.allowedOrigins` unless intentionally required and additionally protected.

(As written by CVE List.)

## Affected

- vercel next.js: >= 16.0.1, < 16.1.7; from 16.0.1 before 16.1.7
- next (npm): from 16.0.1 before 16.1.7

## Every score

- GitHub_M: CVSS:4.0 5.3 Medium `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N`
- NVD: CVSS:3.1 4.3 Medium `CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N`

## References

- <https://github.com/vercel/next.js/security/advisories/GHSA-mq59-m269-xvcx> (mitigation, vendor-advisory, web)
- <https://github.com/vercel/next.js/commit/a27a11d78e748a8c7ccfd14b7759ad2b9bf097d8> (patch, web)
- <https://github.com/vercel/next.js/releases/tag/v16.1.7> (release-notes, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-27978> (advisory)
- <https://github.com/vercel/next.js> (package)

## Sources

- CVE List: [CVE-2026-27978](https://www.cve.org/CVERecord?id=CVE-2026-27978), CVE Terms of Use, modified 2026-03-18
- GitHub Advisory Database: [GHSA-mq59-m269-xvcx](https://github.com/advisories/GHSA-mq59-m269-xvcx), CC-BY-4.0, modified 2026-03-19
- NVD: [CVE-2026-27978](https://nvd.nist.gov/vuln/detail/CVE-2026-27978), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2026-27978 · Whole record: https://cve.day/CVE-2026-27978.json · Rebuilt by cve.day 2026-11-25T22:59:16.066Z
