CVE-2013-7035: Cross-site scripting in React key generation
CVE-2013-7035 is a cross-site scripting vulnerability in React affecting 0.5.x before 0.5.2 and 0.4.x before 0.4.2. According to the provided advisory, the issue is caused by improper sanitization of input used to create keys. If an application derives a React key from attacker-controlled input, the unsanitized value can be incorporated in a way that enables script execution in the victim's browser context.
Impact, mitigation & remediation
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Successful exploitation can allow arbitrary JavaScript execution in the context of the affected user's browser session. This can enable session theft, DOM manipulation, data exfiltration, phishing within the trusted origin, and other client-side actions available to injected script under the application's origin.
Mitigation
If you can’t patch tonight, do this now.
Avoid generating React keys from untrusted or user-controlled input. Where such input cannot be avoided, validate and sanitize it before use, and reduce XSS impact with standard browser-side controls such as a restrictive Content Security Policy. These measures are compensating controls; upgrading to a fixed React version is the primary remediation.
Remediation
Patch, then assume compromise.
Upgrade React 0.5.x to version 0.5.2 or later, or React 0.4.x to version 0.4.2 or later, as specified in the advisory.
Exploits
No public exploits tracked yet. Mallory keeps watching.
References
Frequently asked questions
- Is CVE-2013-7035 exploited in the wild?
- As of Jun 12, 2026, Mallory has no reports of CVE-2013-7035 being exploited in the wild. It is not listed in CISA KEV.
- Is there a public exploit for CVE-2013-7035?
- As of Jun 12, 2026, Mallory has found no public exploit for CVE-2013-7035.
- Is there a patch for CVE-2013-7035?
- Upgrade React 0.5.x to version 0.5.2 or later, or React 0.4.x to version 0.4.2 or later, as specified in the advisory.
Recent activity
No public activity tracked yet. Mallory keeps watching.
No public activity observed for this vulnerability.