Description
DOMPurify is a DOM-only cross-site scripting sanitizer for HTML, MathML, and SVG. Prior to 3.4.6, DOMPurify.sanitize(root, { IN_PLACE: true }) could preserve event-handler attributes on an attacker-controlled <form> root when a descendant name clobbered properties checked by _isClobbered, because _forceRemove no-opped on the parent-less root and _sanitizeAttributes returned early. This issue is fixed in version 3.4.6.
Published: 2026-07-14
Score: 6.1 Medium
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability lies in the IN_PLACE mode of DOMPurify’s sanitize function. Prior to version 3.4.6, calling DOMPurify.sanitize on a <form> element as the root could allow attacker‑controlled event‑handler attributes to persist if a descendant’s name clobbered a property checked by the internal _isClobbered routine. Because the root has no parent, the _forceRemove step is a no‑op and the _sanitizeAttributes routine returns early, the clobbered attributes are not removed. The result is that malicious scripts can remain in the sanitized output and execute in the browser, enabling cross‑site scripting.

Affected Systems

DOMPurify, distributed by cure53, versions prior to 3.4.6.

Risk and Exploitability

The CVSS score of 6.1 classifies this vulnerability as moderate, while the EPSS score of less than 1% suggests a very low likelihood of exploitation in the wild. It is not listed in the CISA KEV catalog, and the attack requires crafted client‑side code that is sanitised with IN_PLACE mode, making exploitation mainly relevant to developers who include un content in DOMPurify’s IN_PLACE root.

Generated by OpenCVE AI on July 31, 2026 at 05:06 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to DOMPurify version 3.4.6 or later, which removes the clobbering issue.
  • If upgrading is not possible, avoid using the IN_PLACE option when sanitising content that may contain attacker‑controlled event‑handler attributes.
  • If upgrading cannot be performed and IN_PLACE must be used, manually strip event‑handler attributes from the root element before sanitisation to ensure no preserved attributes remain.

Generated by OpenCVE AI on July 31, 2026 at 05:06 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-r47g-fvhr-h676 DOMPurify: IN_PLACE mode preserves attributes of a clobbered root element, allowing XSS via attacker-controlled root DOM
History

Wed, 15 Jul 2026 16:00:00 +0000

Type Values Removed Values Added
First Time appeared Cure53
Cure53 dompurify
Vendors & Products Cure53
Cure53 dompurify

Wed, 15 Jul 2026 15:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

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


Wed, 15 Jul 2026 12:15:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

threat_severity

Moderate


Tue, 14 Jul 2026 20:30:00 +0000

Type Values Removed Values Added
Description DOMPurify is a DOM-only cross-site scripting sanitizer for HTML, MathML, and SVG. Prior to 3.4.6, DOMPurify.sanitize(root, { IN_PLACE: true }) could preserve event-handler attributes on an attacker-controlled <form> root when a descendant name clobbered properties checked by _isClobbered, because _forceRemove no-opped on the parent-less root and _sanitizeAttributes returned early. This issue is fixed in version 3.4.6.
Title DOMPurify: IN_PLACE mode preserves attributes of a clobbered root element, allowing XSS via attacker-controlled root DOM
Weaknesses CWE-1321
CWE-693
CWE-79
References
Metrics cvssV3_1

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


Subscriptions

Cure53 Dompurify
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-07-15T14:17:27.943Z

Reserved: 2026-05-30T02:43:33.107Z

Link: CVE-2026-49459

cve-icon Vulnrichment

Updated: 2026-07-15T14:17:23.013Z

cve-icon NVD

No data.

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-07-14T20:01:44Z

Links: CVE-2026-49459 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-07-31T05:15:03Z

Weaknesses
  • CWE-1321

    Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')

  • CWE-693

    Protection Mechanism Failure

  • CWE-79

    Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')