XSS in Cure53 Dompurify
CVE-2026-65900
DOMPurify versions >=3.0.0 and before 3.4.8, when configured with SAFE_FOR_TEMPLATES together with a DOM output mode (RETURN_DOM, RETURN_DOM_FRAGMENT, or IN_PLACE), fail to strip template expressions (e.g. ${evil}, {{evil}}, <%evil%>) inside <template> element content. The final normalization/scrub pass (_scrubTemplateExpressions) uses a NodeIterator and node.normalize() that do not descend into template.content, so expressions that only form after adjacent text nodes merge survive sanitization. This bypasses SAFE_FOR_TEMPLATES and can allow a downstream template engine to evaluate attacker-supplied expressions. The string output path is not affected.
Vulnerability class: XSS (Cross-Site Scripting)
Published · last modified .
CVSS v3 metric
CVSS v3 base score 6.1 (Medium). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N.
EPSS exploit prediction
EPSS 0.003, 24.2th percentile (scored ); unchanged over 30 days. About EPSS.
Affected products
- Cure53 Dompurify — versions 3.0.0, 3.4.8
Weakness classification (CWE)
References
- GitHub Security Advisory (GHSA-gvmj-g25r-r7wr) (vendor-advisory, Exploit, Third Party Advisory)
- VulnCheck Advisory: DOMPurify before 3.4.8 Template Expression Injection via RETURN_DOM (Third Party Advisory, third-party-advisory)