CVE-2025-68470: React Router has unexpected external redirect via untrusted paths
An attacker-supplied path can be crafted so that when a React Router application navigates to it via navigate(), <Link>, or redirect(), the app performs a navigation/redirect to an external URL. This is only an issue if developers pass untrusted content into navigation paths in their application code.
Other sources
React Router is a router for React. In versions 6.0.0 through 6.30.1 and 7.0.0 through 7.9.5, an attacker-supplied path can be crafted so that when a React Router application navigates to it via navigate(), <Link>, or redirect(), the app performs a navigation/redirect to an external URL. This is only an issue if you are passing untrusted content into navigation paths in your application code. This issue has been patched in versions 6.30.2 and 7.9.6.
— MITRE
React Router is a router for React. In versions 6.0.0 through 6.30.1 and 7.0.0 through 7.9.5, an attacker-supplied path can be crafted so that when a React Router application navigates to it via navigate(), Link, or redirect(), the app performs a navigation/redirect to an external URL. This is only an issue if you are passing untrusted content into navigation paths in your application code. This issue has been patched in versions 6.30.2 and 7.9.6.
— IBM
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
npm/react-routerto a version that resolves this vulnerability.Fixed in 7.9.6 - Upgrade
Upgrade
npm/react-routerto a version that resolves this vulnerability.Fixed in 6.30.2 - Upgrade
Upgrade
React Routerto a version that resolves this vulnerability.Fixed in 6.30.2 - Upgrade
Upgrade
React Routerto a version that resolves this vulnerability.Fixed in 7.9.6
Event History
Frequently Asked Questions
What is the severity of CVE-2025-68470?
CVE-2025-68470 is classified as a medium severity vulnerability due to the potential for unauthorized redirection to external URLs.
How do I fix CVE-2025-68470?
To fix CVE-2025-68470, upgrade to React Router version 7.9.6 or 6.30.2, which contains the necessary security patches.
What types of applications are affected by CVE-2025-68470?
CVE-2025-68470 affects React Router applications that accept untrusted input for navigation paths.
What are the consequences of not addressing CVE-2025-68470?
Failure to address CVE-2025-68470 could lead to security risks such as phishing attacks through malicious redirection.
Which versions of React Router are vulnerable to CVE-2025-68470?
Versions of React Router from 6.0.0 to 6.30.1 and from 7.0.0 to 7.9.5 are vulnerable to CVE-2025-68470.