CVE-2026-44581
next.js: Next.js: Stored Cross-Site Scripting via malformed nonce values in cached responses
Severity
ModerateRed Hat Product Security
CVSS 3.1
Review impact separately from score.
Published · May 14, 2026
Updated · July 7, 2026
Description
A flaw was found in Next.js. This vulnerability, a type of stored cross-site scripting (XSS), allows a remote attacker to inject malicious scripts into web pages. By manipulating nonce values derived from request headers, an attacker can poison cached responses, leading to arbitrary script execution in the browsers of subsequent visitors.
Statement
Moderate: This stored cross-site scripting (XSS) flaw in Next.js, a component used in Red Hat AMQ, arises from improper handling of malformed Content Security Policy (CSP) nonce values. When App Router applications are deployed behind shared caches and rely on CSP nonces, an attacker can inject malicious scripts into cached responses, impacting subsequent users. Exploitation requires specific application configurations and the ability to manipulate request headers.
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 · 4.2CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:N
CWE-79 · Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')