XSS in Facebook React
CVE-2018-6341
React applications which rendered to HTML using the ReactDOMServer API were not escaping user-supplied attribute names at render-time. That lack of escaping could lead to a cross-site scripting vulnerability. This issue affected minor releases 16.0.x, 16.1.x, 16.2.x, 16.3.x, and 16.4.x. It was fixed in 16.0.1, 16.1.2, 16.2.1, 16.3.3, and 16.4.2.
Vulnerability class: XSS (Cross-Site Scripting)
Published · last modified .
CVSS v3 metric
CVSS v3 base score 6.1 (Medium). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N.
EPSS exploit prediction
EPSS 0.034, 89.1th percentile (scored ); unchanged over 30 days. About EPSS.
Affected products
- Facebook React
- Facebook React-Dom — versions 16.4.2, 16.4.0, 16.3.3
Weakness classification (CWE)
Public exploits and proof-of-concept code
2 public repositories with exploit or proof-of-concept code for this CVE:
- nitindevelopermca/react-CVE-2018-6341 (last pushed 2026-08-04)
- diwangs/react16-ssr (last pushed 2023-03-20): CVE-2018-6341
Also mentioned in 4 other repositories (freeshineit/react-changelog, JCDMeira/release-notes-react, msgre/scratch3, …). These reference the CVE in a list, notes or a scanner and are not exploit code for it.
References
- reactjs.org/blog/2018/08/01/react-v-16-4-2.html (Vendor Advisory)
- twitter.com/reactjs/status/1024745321987887104 (Vendor Advisory)
This CVE has public exploit evidence. See the latest CVEs with public exploits.