NetSight
high8.2

CVE-2026-21884

React Router SSR XSS in ScrollRestoration

Impact

A XSS vulnerability exists in in React Router's `<ScrollRestoration>` API in [Framework Mode](https://reactrouter.com/start/modes#framework) 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. > [!NOTE] > This does not impact applications if developers have [disabled server-side rendering](https://reactrouter.com/how-to/spa) in Framework Mode, or if they are using [Declarative Mode](https://reactrouter.com/start/modes#declarative) (`<BrowserRouter>`) or [Data Mode](https://reactrouter.com/start/modes#data) (`createBrowserRouter`/`<RouterProvider>`).

Affected packages

EcosystemPackageAffectedFixed in
npmreact-router>= 7.0.0, < 7.12.07.12.0
npm@remix-run/react< 2.17.32.17.3

Affected products

VendorProductAffected versions
ShopifyReact-Router
from 7.0.0 through 7.11.0
ShopifyRemix-Run\/React
before 2.17.3

Weakness classification

References