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, DOMParser.parseFromString() can silently accept an end tag such as </a\njunk>, close the element, and discard the trailing content. On 0.9.x, the lib/sax.js end-tag validator inherits the multiline flag from reg(), allowing the first line to satisfy the anchored XML ETag production; older lines have no equivalent residue validation. This parser differential can bypass a parse-before-trust well-formedness gate, although it does not inject the discarded content; onError on 0.9.x and errorHandler on 0.8.x are the relevant reporting interfaces. This issue is fixed in @xmldom/xmldom versions 0.8.15 and 0.9.12; no fixed version is available for xmldom.
Published: 2026-09-01
Score: 6.9 Medium
EPSS: < 1% Very Low
KEV: No
Impact: XML parsing bypass
Action: Patch
AI Analysis

Impact

The vulnerable parser in the xmldom library silently accepts an end tag that is not well‑formed, such as </a\njunk>. This causes the parser to close the element and discard later content without reporting an error. The flaw allows crafted XML to be parsed as if it were valid, bypassing any well‑formedness checks that depend on strict XML syntax enforcement. Consequently, an attacker could supply malicious XML that is considered trustworthy by downstream code, leading to logic or injection problems. This weakness is identified as CWE‑1286.

Affected Systems

The issue affects the @xmldom/xmldom package as well as the older xmldom module. Any version before 0.8.15 for the @xmldom package and before 0.9.12 is vulnerable. The same applies to xmldom 0.6.0 and earlier. No fix is available for the legacy xmldom package. The vulnerability is present in environments where the library is used to parse XML from external or untrusted sources.

Risk and Exploitability

The CVSS base score is 6.9, indicating a moderate impact. The EPSS score is not available and the vulnerability is not listed in the CISA KEV catalog, suggesting that it is not known to be actively exploited in the wild. Attackers could exploit the flaw by feeding a specially crafted XML document to an application that relies on xmldom’s parseFromString, thereby bypassing input validation. The risk is higher in systems that trust the output of the parser without additional validation, and lower in those that perform strict checks independently.

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

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Update @xmldom/xmldom to version 0.8.15 or later, or 0.9.12 or later, to ensure the multiline flag is correctly handled and malformed end tags are rejected.
  • If migrating to a newer package is not possible, avoid using parseFromString to process XML that originates from untrusted sources; instead validate the XML against an XML schema or DTD before parsing.
  • Audit application code to remove any implicit trust in the parsing result and enforce strict well‑formedness checks, or use an alternate XML parsing library that provides robust validation.

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

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-6h8r-xr42-gp59 xmldom: Parser silently accepts a not-well-formed end tag whose name is followed by a line break and trailing content
History

Wed, 02 Sep 2026 00:15:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

cvssV3_1

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

threat_severity

Moderate


Tue, 01 Sep 2026 22:00:00 +0000

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'}


Tue, 01 Sep 2026 14:45:00 +0000

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, DOMParser.parseFromString() can silently accept an end tag such as </a\njunk>, close the element, and discard the trailing content. On 0.9.x, the lib/sax.js end-tag validator inherits the multiline flag from reg(), allowing the first line to satisfy the anchored XML ETag production; older lines have no equivalent residue validation. This parser differential can bypass a parse-before-trust well-formedness gate, although it does not inject the discarded content; onError on 0.9.x and errorHandler on 0.8.x are the relevant reporting interfaces. This issue is fixed in @xmldom/xmldom versions 0.8.15 and 0.9.12; no fixed version is available for xmldom.
Title xmldom: Parser silently accepts a not-well-formed end tag whose name is followed by a line break and trailing content
Weaknesses CWE-1286
References
Metrics cvssV4_0

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


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-09-01T14:53:37.513Z

Reserved: 2026-08-31T20:36:25.744Z

Link: CVE-2026-83611

cve-icon Vulnrichment

Updated: 2026-09-01T14:53:26.076Z

cve-icon NVD

Status : Deferred

Published: 2026-09-01T15:17:39.263

Modified: 2026-09-08T21:11:31.703

Link: CVE-2026-83611

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-09-01T14:34:12Z

Links: CVE-2026-83611 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-09-01T16:30:17Z

Weaknesses
  • CWE-1286

    Improper Validation of Syntactic Correctness of Input