Skip to main content

Boteraser | Website and Server Security Solutions

🛡️ CVE-2026-27977 — next

🟡 CVSS 5.4 — Medium ✅ No Known Exploit CWE-1385 NVD
5.4
CVSS Score
0 Low4 Medium7 High9 Critical10

Description

Next.js: null origin can bypass dev HMR websocket CSRF checks

Summary

In next dev, cross-site protections for internal development endpoints could treat Origin: null as a bypass case even when [allowedDevOrigins](https://nextjs.org/docs/app/api-reference/config/next-config-js/allowedDevOrigins) is configured. This could allow privacy-sensitive or opaque browser contexts, such as sandboxed documents, to access privileged internal dev-server functionality unexpectedly.

Impact

If a developer visits attacker-controlled content while running an affected next dev server with [allowedDevOrigins](https://nextjs.org/docs/app/api-reference/config/next-config-js/allowedDevOrigins) configured, attacker-controlled browser code may be able to connect to internal development endpoints and interact with sensitive dev-server functionality that should have remained blocked.

This issue affects development mode only. It does not affect next start, and it does not expose internal debugging functionality to the network by default.

Patches

Fixed by validating Origin: null through the same cross-site origin-allowance checks used for other origins on internal development endpoints.

Workarounds

If upgrade is not immediately possible:

  • Do not expose next dev to untrusted networks.
  • If you use [allowedDevOrigins](https://nextjs.org/docs/app/api-reference/config/next-config-js/allowedDevOrigins), reject requests and websocket upgrades with Origin: null for internal dev endpoints at your proxy.

How this vulnerability can be exploited

This issue can be reached over the network, attack complexity is low, an attacker needs no privileges on the target. A user must be tricked into taking some action. The scope is unchanged, so the impact stays within the vulnerable component. Rated impact: confidentiality low, integrity low, availability none.

CVSS metrics in full

The score comes from this vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N

  • Attack vector: Network — reachable from anywhere that can route to the service.
  • Attack complexity: Low — the attack works reliably, with no preparation.
  • Privileges required: None — an unauthenticated stranger can try it.
  • User interaction: Required — someone has to click, open or visit something.
  • Scope: Unchanged — the damage stays inside the vulnerable component.
  • Confidentiality impact: Low — limited, and the attacker does not choose what is affected.
  • Integrity impact: Low — limited, and the attacker does not choose what is affected.
  • Availability impact: None.

Weakness class

CVE-2026-27977 is classified as CWE-1385: Missing Origin Validation in WebSockets. The product uses a WebSocket, but it does not properly verify that the source of data or communication is valid.

Affected software

CVE-2026-27977 is recorded against 2 packages.

  • next
  • next.js (from 16.0.1 up to 16.1.7)

Timeline and source

Published on 17 March 2026 and last revised on 25 March 2026. No public exploit is currently recorded for this entry. A vendor advisory or fix has been published. Record sourced from NVD.

References

github.com (Web)
nvd.nist.gov (Advisory)
github.com (Web)
github.com (Package)
github.com (Web)

Other advisories for this package

next has other advisories on record. If you are patching this one, these are worth checking on the same host:

Same weakness in other software

These advisories are the same class of weakness (CWE-1385: Missing Origin Validation in WebSockets) in other software:

Details

Severity LOW
CVSS Score 5.4
CVSS Vector CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
CWE CWE-1385
Public Exploit ✅ No
Source NVD
Published 2026-03-17
Updated 2026-08-20
Modified 2026-03-25

Affected Packages

Software From version Fixed in
next
next.js 16.0.1 16.1.7

Similar Threats

Vulnerability Monitoring

Track new vulnerabilities in next

CVE-2026-27977 is rated CVSS 5.4 Medium. BotEraser monitors your WordPress installation and notifies you when software you use appears in our vulnerability database.

Set Up Free Alerts →

No credit card required  ·  Results in minutes

ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.

Browse related advisories

All advisoriesCVECVE 2026