CVE-2026-83616

xmldom: Processing Instruction Target Injection Bypasses requireWellFormed

Published Sep 1, 2026 CVSS 4.0 · 8.7 High EPSS < 1% KEV · Not listed
Description
xmldom is a pure JavaScript W3C standard-based (XML DOM Level 2 Core) DOMParser and XMLSerializer module. Prior to @xmldom/xmldom versions 0.8.15 and 0.9.12, and in xmldom version 0.6.0 and earlier, Document.createProcessingInstruction(target, data) in lib/dom.js accepts an unvalidated target, while the requireWellFormed: true serializer checks only for a colon and the reserved case-insensitive xml name on 0.9.x and performs no target check on 0.8.x. Because serialization emits <?target data?>, a target containing >, ?, whitespace, or another invalid XML-name character can break the processing-instruction boundary and inject XML structure. This issue is fixed in @xmldom/xmldom versions 0.8.15 and 0.9.12; no fixed version is available for xmldom.

Analysis

AI-generated

Technical impact

The vulnerability is caused by Document.createProcessingInstruction accepting an unvalidated target string. An attacker can craft a target containing characters such as >, ?, or whitespace that break the <?target data?> boundary, allowing arbitrary XML structure to be injected into the processed document. Because the requireWellFormed serializer checks only for a colon and the case‑insensitive xml name on some releases and performs no target check on others, the injected XML can alter document semantics or introduce malicious content when the XML is later consumed.

Affected Systems

The affected component is the xmldom JavaScript library. Versions prior to 0.8.15 and 0.9.12, and all 0.6.0 and earlier releases of xmldom, fail to validate the processing instruction target. No fix exists for the older xmldom package; the patch is only available in the @xmldom/xmldom releases 0.8.15 and 0.9.12.

Risk and Exploitability

The CVSS score of 8.7 indicates high severity, but the EPSS score is not available and the vulnerability is not listed in CISA KEV. Exploitation requires an application that uses xmldom to create a processing instruction and the ability to supply an arbitrary target string. In many web or Node.js contexts this could be achieved through user input or data files, enabling the injection of malicious XML before the document is used by downstream components.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the xmldom library to @xmldom/xmldom v0.8.15 or later, ideally v0.9.12+.
  • If the project must use older xmldom versions, switch to a maintained alternative XML parser that enforces target validation.
  • Prior to invoking createProcessingInstruction, validate the target string against the XML name specification, rejecting any characters such as >, ?, whitespace or additional colons beyond the first.

Generated by OpenCVE AI on September 1, 2026 at 16:47 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-c7q8-3ch8-vqpv xmldom: Processing Instruction Target Injection Bypasses requireWellFormed
History
Type Values Removed Values Added
References
Metrics threat_severity

None

cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N'}

threat_severity

Important

Type Values Removed Values Added
First Time appeared Xmldom
Xmldom xmldom
Vendors & Products Xmldom
Xmldom xmldom
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description xmldom is a pure JavaScript W3C standard-based (XML DOM Level 2 Core) DOMParser and XMLSerializer module. Prior to @xmldom/xmldom versions 0.8.15 and 0.9.12, and in xmldom version 0.6.0 and earlier, Document.createProcessingInstruction(target, data) in lib/dom.js accepts an unvalidated target, while the requireWellFormed: true serializer checks only for a colon and the reserved case-insensitive xml name on 0.9.x and performs no target check on 0.8.x. Because serialization emits <?target data?>, a target containing >, ?, whitespace, or another invalid XML-name character can break the processing-instruction boundary and inject XML structure. This issue is fixed in @xmldom/xmldom versions 0.8.15 and 0.9.12; no fixed version is available for xmldom.
Title xmldom: Processing Instruction Target Injection Bypasses requireWellFormed
Weaknesses CWE-91
References
Metrics cvssV4_0

{'score': 8.7, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N'}

Weaknesses
  • CWE-91

    XML Injection (aka Blind XPath Injection)

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Sep 1, 2026, 3:18 PM
Reserved
Aug 31, 2026, 8:36 PM
Status
Deferred
Published
Sep 1, 2026, 3:17 PM
Modified
Sep 8, 2026, 9:11 PM
Severity
Important
Public date
Sep 1, 2026, 2:45 PM