Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. @xmldom/xmldom
  4. ›
  5. CVE-2026-34601

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

April 1, 2026

@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.

The sequence ]]> is not allowed inside CDATA content and must be rejected or safely handled during serialization. (MDN Web Docs)

References

  • github.com/advisories/GHSA-wh4c-j3r5-mjhp
  • github.com/xmldom/xmldom
  • github.com/xmldom/xmldom/commit/2b852e836ab86dbbd6cbaf0537f584dd0b5ac184
  • github.com/xmldom/xmldom/releases/tag/0.8.12
  • github.com/xmldom/xmldom/releases/tag/0.9.9
  • github.com/xmldom/xmldom/security/advisories/GHSA-wh4c-j3r5-mjhp
  • nvd.nist.gov/vuln/detail/CVE-2026-34601

Code Behaviors & Features

Detect and mitigate CVE-2026-34601 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 0.8.12, all versions starting from 0.9.0 before 0.9.9

Fixed versions

  • 0.8.12
  • 0.9.9

Solution

Upgrade to versions 0.8.12, 0.9.9 or above.

Impact 7.5 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N

Learn more about CVSS

Weakness

  • CWE-91: XML Injection (aka Blind XPath Injection)

Source file

npm/@xmldom/xmldom/CVE-2026-34601.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 01 Apr 2026 12:19:07 +0000.