CVE-2026-65899
Undergoing Analysis Undergoing Analysis - In Progress

Trusted Types Policy Bypass in DOMPurify

Vulnerability report for CVE-2026-65899, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-07-23

Last updated on: 2026-07-23

Assigner: VulnCheck

Description

DOMPurify 3.0.0 before 3.4.9 does not reset the retained Trusted Types policy when clearConfig() is called, so a DOMPurify instance reused across trust boundaries stays bound to a previously supplied TRUSTED_TYPES_POLICY. A later caller that requests RETURN_TRUSTED_TYPE output receives a TrustedHTML object created by the old (potentially unsafe) policy rather than a clean default, which can lead to script execution at a Trusted Types sink. Passing TRUSTED_TYPES_POLICY: null on the later call also does not clear the retained policy.

CVSS Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-07-23
Last Modified
2026-07-23
Generated
2026-07-23
AI Q&A
2026-07-23
EPSS Evaluated
N/A
NVD
EUVD

Affected Vendors & Products

Showing 1 associated CPE
Vendor Product Version / Range
dompurify dompurify to 3.4.9 (exc)

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-693 The product does not use or incorrectly uses a protection mechanism that provides sufficient defense against directed attacks against the product.

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

DOMPurify versions before 3.4.9 fail to reset the retained Trusted Types policy when clearConfig() is called. This means a reused DOMPurify instance stays bound to a previously set TRUSTED_TYPES_POLICY. Later calls requesting RETURN_TRUSTED_TYPE output may receive a TrustedHTML object from the old policy instead of a clean default, potentially leading to script execution at a Trusted Types sink.

Impact Analysis

If you use DOMPurify across different trust boundaries, an attacker could exploit this to execute malicious scripts in your application. This happens when a reused DOMPurify instance retains an unsafe policy, causing it to generate TrustedHTML objects that bypass security checks. Even setting TRUSTED_TYPES_POLICY to null does not clear the retained policy.

Compliance Impact

This vulnerability could lead to unauthorized script execution, potentially violating data integrity and confidentiality requirements in GDPR and HIPAA. If exploited, it may result in data breaches or unauthorized access to sensitive information, undermining compliance with these regulations.

Mitigation Strategies

Upgrade DOMPurify to version 3.4.9 or later to address the Trusted Types policy state contamination issue. Review any custom policies or configurations that may have been set in reused DOMPurify instances to ensure they are safe and properly reset.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-65899. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart