CVE-2024-51479
next.js: next: authorization bypass in Next.js
Severity
ModerateRed Hat Product Security
CVSS 3.1
Review impact separately from score.
Published · December 18, 2024
Updated · July 3, 2026
Description
A flaw was found in the Next.js framework. An incorrectly sanitized query parameter can cause an invalid routing condition, resulting in the wrong route being served to users and allowing authorization bypass when an application is performing path-based middleware authorization.
Statement
This issue affects self-hosted applications with a missing i18n configuration performing path-based middleware authorization. Applications hosted on Vercel are not vulnerable to this vulnerability.
Additionally, only pages under the root directory of the application are vulnerable to this issue, for example:
https://example.com/: not vulnerable
https://example.com/foo: vulnerable
https://example.com/foo/bar: not vulnerable
CVSS score applicability
The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.
Mitigation
Mitigation for this issue is either not available or the currently available options do not meet the Red Hat Product Security criteria comprising ease of use and deployment, applicability to widespread installation base or stability.
CVSS / CWE
CVSS 3.1 · 7.5CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
CWE-285 · Improper Authorization