CVE-2026-21884: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in remix-run react-router
React Router is a router for React. In @remix-run/react version prior to 2.17.3. and react-router 7.0.0 through 7.11.0, a XSS vulnerability exists in in React Router's <ScrollRestoration> API in Framework Mode when using the getKey/storageKey props during Server-Side Rendering which could allow arbitrary JavaScript execution during SSR if untrusted content is used to generate the keys. There is no impact if server-side rendering in Framework Mode is disabled, or if Declarative Mode (<BrowserRouter>) or Data Mode (createBrowserRouter/<RouterProvider>) is being used. This issue has been patched in @remix-run/react version 2.17.3 and react-router version 7.12.0.
AI Analysis
Technical Summary
CVE-2026-21884 is a cross-site scripting (XSS) vulnerability classified under CWE-79, found in the React Router library, a widely used routing solution for React applications. The vulnerability specifically affects versions prior to 2.17.3 of @remix-run/react and versions 7.0.0 through 7.11.0 of react-router. It arises in the <ScrollRestoration> API when operating in Framework Mode with server-side rendering (SSR). The issue occurs if the getKey or storageKey properties are used to generate keys from untrusted input during SSR, leading to improper neutralization of input. This improper sanitization allows an attacker to inject malicious JavaScript code that executes on the server side during page generation. Notably, this vulnerability does not impact applications that disable SSR in Framework Mode or those using Declarative Mode (<BrowserRouter>) or Data Mode (createBrowserRouter/<RouterProvider>). The vulnerability has been addressed in @remix-run/react version 2.17.3 and react-router version 7.12.0. The CVSS v3.1 score of 8.2 reflects a high severity, with an attack vector of network, low attack complexity, no privileges required, but requiring user interaction. The scope is changed, impacting confidentiality highly, with limited integrity impact and no availability impact. No known exploits are currently reported in the wild. This vulnerability is critical for applications that rely on SSR in Framework Mode and use untrusted data for key generation in the affected React Router versions.
Potential Impact
For European organizations, the impact of CVE-2026-21884 can be significant, especially for those deploying React applications using SSR in Framework Mode with the vulnerable versions of React Router. Successful exploitation could lead to arbitrary JavaScript execution during server-side rendering, potentially exposing sensitive data processed on the server, including user session information or internal application logic. This compromises confidentiality and could facilitate further attacks such as session hijacking, data theft, or injection of malicious payloads affecting end users. Since React is widely adopted in Europe across various sectors including finance, healthcare, and e-commerce, organizations using SSR with Framework Mode are at heightened risk. The vulnerability does not affect client-side only applications or those using other routing modes, limiting the scope somewhat. However, the ease of exploitation (network vector, no privileges) and high confidentiality impact make this a critical concern for web applications that handle sensitive data or operate in regulated environments under GDPR. The absence of known exploits in the wild provides a window for proactive mitigation, but the potential damage warrants urgent patching and review of SSR configurations.
Mitigation Recommendations
European organizations should immediately audit their React applications to identify usage of @remix-run/react versions prior to 2.17.3 or react-router versions between 7.0.0 and 7.11.0, particularly focusing on those employing SSR in Framework Mode with the <ScrollRestoration> API and getKey/storageKey props. The primary mitigation is to upgrade to @remix-run/react 2.17.3 or react-router 7.12.0 or later, where the vulnerability is patched. If upgrading is not immediately feasible, organizations should disable SSR in Framework Mode or avoid using getKey/storageKey with untrusted input to prevent exploitation. Additionally, implement strict input validation and sanitization on any data used in key generation to neutralize potentially malicious content. Conduct thorough code reviews to ensure no untrusted data is passed to these properties. Employ Content Security Policy (CSP) headers to limit the impact of potential XSS attacks. Monitor application logs for unusual activity related to SSR processes. Finally, maintain an incident response plan to quickly address any exploitation attempts.
Affected Countries
Germany, France, United Kingdom, Netherlands, Sweden, Italy, Spain, Poland
CVE-2026-21884: CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in remix-run react-router
Description
React Router is a router for React. In @remix-run/react version prior to 2.17.3. and react-router 7.0.0 through 7.11.0, a XSS vulnerability exists in in React Router's <ScrollRestoration> API in Framework Mode when using the getKey/storageKey props during Server-Side Rendering which could allow arbitrary JavaScript execution during SSR if untrusted content is used to generate the keys. There is no impact if server-side rendering in Framework Mode is disabled, or if Declarative Mode (<BrowserRouter>) or Data Mode (createBrowserRouter/<RouterProvider>) is being used. This issue has been patched in @remix-run/react version 2.17.3 and react-router version 7.12.0.
AI-Powered Analysis
Technical Analysis
CVE-2026-21884 is a cross-site scripting (XSS) vulnerability classified under CWE-79, found in the React Router library, a widely used routing solution for React applications. The vulnerability specifically affects versions prior to 2.17.3 of @remix-run/react and versions 7.0.0 through 7.11.0 of react-router. It arises in the <ScrollRestoration> API when operating in Framework Mode with server-side rendering (SSR). The issue occurs if the getKey or storageKey properties are used to generate keys from untrusted input during SSR, leading to improper neutralization of input. This improper sanitization allows an attacker to inject malicious JavaScript code that executes on the server side during page generation. Notably, this vulnerability does not impact applications that disable SSR in Framework Mode or those using Declarative Mode (<BrowserRouter>) or Data Mode (createBrowserRouter/<RouterProvider>). The vulnerability has been addressed in @remix-run/react version 2.17.3 and react-router version 7.12.0. The CVSS v3.1 score of 8.2 reflects a high severity, with an attack vector of network, low attack complexity, no privileges required, but requiring user interaction. The scope is changed, impacting confidentiality highly, with limited integrity impact and no availability impact. No known exploits are currently reported in the wild. This vulnerability is critical for applications that rely on SSR in Framework Mode and use untrusted data for key generation in the affected React Router versions.
Potential Impact
For European organizations, the impact of CVE-2026-21884 can be significant, especially for those deploying React applications using SSR in Framework Mode with the vulnerable versions of React Router. Successful exploitation could lead to arbitrary JavaScript execution during server-side rendering, potentially exposing sensitive data processed on the server, including user session information or internal application logic. This compromises confidentiality and could facilitate further attacks such as session hijacking, data theft, or injection of malicious payloads affecting end users. Since React is widely adopted in Europe across various sectors including finance, healthcare, and e-commerce, organizations using SSR with Framework Mode are at heightened risk. The vulnerability does not affect client-side only applications or those using other routing modes, limiting the scope somewhat. However, the ease of exploitation (network vector, no privileges) and high confidentiality impact make this a critical concern for web applications that handle sensitive data or operate in regulated environments under GDPR. The absence of known exploits in the wild provides a window for proactive mitigation, but the potential damage warrants urgent patching and review of SSR configurations.
Mitigation Recommendations
European organizations should immediately audit their React applications to identify usage of @remix-run/react versions prior to 2.17.3 or react-router versions between 7.0.0 and 7.11.0, particularly focusing on those employing SSR in Framework Mode with the <ScrollRestoration> API and getKey/storageKey props. The primary mitigation is to upgrade to @remix-run/react 2.17.3 or react-router 7.12.0 or later, where the vulnerability is patched. If upgrading is not immediately feasible, organizations should disable SSR in Framework Mode or avoid using getKey/storageKey with untrusted input to prevent exploitation. Additionally, implement strict input validation and sanitization on any data used in key generation to neutralize potentially malicious content. Conduct thorough code reviews to ensure no untrusted data is passed to these properties. Employ Content Security Policy (CSP) headers to limit the impact of potential XSS attacks. Monitor application logs for unusual activity related to SSR processes. Finally, maintain an incident response plan to quickly address any exploitation attempts.
Affected Countries
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-01-05T17:24:36.928Z
- Cvss Version
- 3.1
- State
- PUBLISHED
Threat ID: 6961c40f19784dcf52ace86a
Added to database: 1/10/2026, 3:14:23 AM
Last enriched: 1/10/2026, 3:29:38 AM
Last updated: 1/10/2026, 11:07:33 PM
Views: 21
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Related Threats
CVE-2026-0824: Cross Site Scripting in questdb ui
MediumCVE-2025-13393: CWE-918 Server-Side Request Forgery (SSRF) in marceljm Featured Image from URL (FIFU)
MediumCVE-2025-12379: CWE-79 Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') in averta Shortcodes and extra features for Phlox theme
MediumCVE-2026-0822: Heap-based Buffer Overflow in quickjs-ng quickjs
MediumCVE-2026-0821: Heap-based Buffer Overflow in quickjs-ng quickjs
MediumActions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console in Console -> Billing for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.