Skip to main content

DOMPurify CVE-2026-65901

| EUVDEUVD-2026-48270 MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2026-07-23 VulnCheck
5.1
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Identify application using DOMPurify IN_PLACE mode
  2. Delivery
    Establish same-origin access via iframe or popup
  3. Exploit
    Craft live DOM node with clobbered nodeName
  4. Execution
    Pass hostile node to sanitize(node, {IN_PLACE: true})
  5. Persist
    DOMPurify misclassifies script as allowed
  6. Impact
    Script executes on DOM insertion

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires three simultaneous conditions: (1) the vulnerable application must call DOMPurify.sanitize() with the IN_PLACE: true option - the default string-based sanitization path is entirely unaffected; (2) the node supplied to sanitize() must be a live DOM object under attacker influence, specifically delivered via a same-origin iframe (node passed by reference), a same-origin window.open() popup (node passed by reference), or a node adopted into the host document via document.adoptNode() before sanitization; and (3) a same-origin relationship must exist between the attacker's context and the target, which typically requires the attacker to control a resource on the same origin as the application (e.g., via a stored XSS vector, an open redirect to a same-origin page, or postMessage abuse). The attack does not apply to string HTML inputs, cross-origin iframes (blocked by same-origin policy), or any code path that does not use IN_PLACE mode. Limits on real-world exploitation: the same-origin requirement is a meaningful prerequisite, and most typical DOMPurify integrations sanitize HTML strings rather than live DOM nodes in IN_PLACE mode.

Impact

The CVSS 4.0 score of 5.1 (AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N) reflects a medium-severity finding with the scope of impact limited to the subsequent system (victim browser), not the vulnerable system itself. The UI:A (active user interaction) metric and the constrained attack surface - exploitation is gated on the application calling sanitize() in IN_PLACE mode AND accepting attacker-controlled live DOM nodes - significantly reduce real-world risk compared to a generic XSS in a web application. DOMPurify is a security control, so bypass of its sanitization is categorically more serious than an equivalent flaw in business logic: developers place explicit trust in it. No KEV listing exists, and no standalone POC code has been published; however, the GHSA advisory discloses code-level detail (exact function names, guard conditions, and three concrete exploit vectors) that materially lowers the barrier to exploitation. EPSS data was not supplied. The absence of a fix version (fixed in: None) elevates urgency for any caller using IN_PLACE mode. The assigned CVSS 4.0 AC:L is arguably generous given the required same-origin relationship and specific API usage; real-world complexity is higher than AC:L implies.

Exploit ScenarioDerived

An attacker hosts a malicious page that opens a same-origin popup or embeds a same-origin iframe, constructs a live DOM node with a real script child whose nodeName property is clobbered to reflect an allowed tag name, and passes that node by reference to a vulnerable application calling DOMPurify.sanitize(node, { IN_PLACE: true }). DOMPurify's _sanitizeElements pipeline trusts the clobbered nodeName, retains the script element, and when the sanitized tree is inserted into the host document the script executes in the victim's browser context. No standalone POC has been published, but the GHSA advisory provides sufficient code-level detail to reconstruct the exploit.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
No patch listed yet 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 23, 2026

Cross-site scripting in DOMPurify 3.4.6 and earlier enables script execution when the library's IN_PLACE sanitization mode processes attacker-supplied live DOM nodes whose nodeName property has been clobbered to masquerade as an allowed element. The vulnerability bypasses DOMPurify's existing clobbering protections, which were scoped only to form elements, leaving all other live non-form nodes susceptible to nodeName manipulation. No vendor-released patch exists at time of analysis; no public exploit code has been identified, though the GHSA advisory provides a detailed technical breakdown sufficient for exploit construction.

RemediationAI

No vendor-released patch has been identified at time of analysis; the package metadata confirms fixed in: None, and the GHSA advisory at https://github.com/cure53/DOMPurify/security/advisories/GHSA-x4vx-rjvf-j5p4 does not specify a remediated release. The primary compensating control is to avoid calling DOMPurify.sanitize() in IN_PLACE mode on any DOM node sourced from an untrusted or attacker-influenced origin; switching to string-based sanitization via DOMPurify.sanitize(dirtyString) (without the IN_PLACE option) is unaffected by this vulnerability and eliminates the attack surface entirely. Applications that must use IN_PLACE mode should validate that input nodes originate exclusively from fully trusted, application-controlled sources - not from cross-iframe references, popups, or document.adoptNode() on externally sourced nodes - treating any such node as untrusted regardless of apparent origin. Monitor the DOMPurify GitHub repository and npm release feed for a patched version.

Affected VersionsENISA

DOMPurify 0 ≤3.4.6

Affected Packages

npm dompurify no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in npm

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

DOMPurify (cure53/dompurify, CPE cpe:2.3:a:cure53:dompurify:*:*:*:*:*:*:*:*) is a widely used npm library for sanitizing HTML and DOM content to prevent XSS (CWE-79). The library supports two primary input modes: string-based sanitization, which serializes and re-parses HTML into a clean tree, and IN_PLACE mode (IN_PLACE: true), which operates directly on a live DOM node passed by reference. In IN_PLACE mode, the _sanitizeElements function reads currentNode.nodeName to determine whether an element should be permitted or removed. A prior hardening pass introduced _isClobbered() to detect and reject form nodes whose nodeName had been clobbered via DOM property shadowing, but _isClobbered() explicitly returns false for any element that is not a form. Consequently, an attacker can supply a live DOM object - sourced from a same-origin iframe, a same-origin window.open() popup, or a node adopted via document.adoptNode() - that carries a real script child whose nodeName is overridden to resemble an allowed tag. DOMPurify classifies it as benign, retains it in the sanitized tree, and when the tree is inserted into a live document the script executes. String-based sanitization paths are entirely unaffected.

Know when Dompurify gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 5.1 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
vuln.today AI 4.7 MEDIUM

AC:H reflects the same-origin and IN_PLACE-mode prerequisites; S:C and UI:R capture victim-browser XSS with user interaction; no confidentiality or integrity impact on the vulnerable system itself.

3.1 AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N
4.0 AV:N/AC:H/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
SUSE 6.1 HIGH
AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Red Hat 6.1 MEDIUM

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Active
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
None
Vulnerable system: Availability
None
Subsequent system: Confidentiality
Low
Subsequent system: Integrity
Low
Subsequent system: Availability
None

DescriptionCVE.org

DOMPurify through 3.4.6 contains a cross-site scripting vulnerability in IN_PLACE mode that trusts attacker-controlled nodeName on live non-form nodes. Attackers can supply hostile live DOM objects with real script children whose observable nodeName is clobbered to appear as allowed elements, causing scripts to execute when the sanitized tree is inserted into a live document.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 37 npm packages depend on dompurify (3 direct, 34 indirect)

Ecosystem-wide dependent count for version 3.4.6.

Threat Intelligence Overview

EPSS Score
0.2%
Top 95% exploitable
Prevalence
High
dominant HTML sanitization library across npm ecosystem and web frameworks
Exploit
POC
Public exploit code exists
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment Vendor GitHub

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC Yes
EPSS 0.2%
Patch available No
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
No
Human Impact· derived
High
Technical Impact
Partial

Priority Score

46
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

CVE-2024-47875 MEDIUM POC
6.1 Oct 11

DOMPurify is a DOM-only, super-fast, uber-tolerant XSS sanitizer for HTML, MathML and SVG. Rated medium severity (CVSS 6

CVE-2020-26870 MEDIUM POC
6.1 Oct 07

Cure53 DOMPurify before 2.0.17 allows mutation XSS. Rated medium severity (CVSS 6.1), this vulnerability is remotely exp

CVE-2019-16728 MEDIUM POC
6.1 Sep 24

DOMPurify before 2.0.1 allows XSS because of innerHTML mutation XSS (mXSS) for an SVG element or a MATH element, as demo

CVE-2024-48910 CRITICAL
9.8 Oct 31

DOMPurify is a DOM-only, super-fast, uber-tolerant XSS sanitizer for HTML, MathML and SVG. Rated critical severity (CVSS

CVE-2026-65914 MEDIUM POC
5.3 Jul 23

Mutation-XSS in DOMPurify before 3.3.2 enables JavaScript execution in victim browsers when sanitized output is re-inser

CVE-2026-65902 MEDIUM POC
5.3 Jul 23

Hook mutation pollution in DOMPurify <= 3.4.5 allows persistent bypass of HTML sanitization defaults when application-in

CVE-2026-65899 MEDIUM POC
5.1 Jul 23

Trusted Types policy state contamination in DOMPurify 3.0.0-3.4.8 allows a previously supplied TRUSTED_TYPES_POLICY to s

CVE-2026-65913 MEDIUM POC
5.1 Jul 23

Prototype pollution in DOMPurify's USE_PROFILES mode enables DOM-based XSS by causing the sanitizer to accept event hand

CVE-2026-65912 MEDIUM POC
5.1 Jul 23

URI validation bypass in DOMPurify 3.3.1 and earlier allows `javascript:` protocol payloads to survive HTML sanitization

CVE-2026-65900 MEDIUM POC
5.1 Jul 23

SAFE_FOR_TEMPLATES bypass in DOMPurify 3.0.0-3.4.7 allows template expressions such as ${evil}, {{evil}}, and <%evil%> t

CVE-2026-65898 MEDIUM POC
5.1 Jul 23

Stored XSS is achievable in applications using DOMPurify's setConfig() API combined with an uponSanitizeAttribute hook t

CVE-2025-26791 MEDIUM POC
4.5 Feb 14

DOMPurify before 3.2.4 has an incorrect template literal regular expression, sometimes leading to mutation cross-site sc

Vendor StatusVendor

SUSE

Severity: Important
Product Status
SUSE Linux Enterprise Module for SAP Applications 15 SP7 Affected
SUSE Linux Enterprise Server 16.0 Affected
SUSE Linux Enterprise Server 16.1 Affected
SUSE Linux Enterprise Server for SAP Applications 15 SP7 Affected
SUSE Linux Enterprise Server for SAP applications 16.0 Affected

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy