CVE-2026-65904: DOMPurify through 3.3.3 Cross-Site Scripting via IN_PLACE mode

Published Jul 23, 2026
·
Updated

DOMPurify before 3.4.4 fails to sanitize DOM elements passed via INPLACE mode when the element originates from a different window/realm (e.g., an iframe's contentDocument). A cross-realm instanceof check in the private isNode() function returns false for foreign-realm nodes, causing DOMPurify to stringify the element (yielding '[object HTMLDivElement]'), silently reset INPLACE to false, and return the unsanitized element unchanged with any XSS payloads intact.

Other sources

DOMPurify through 3.3.3 fails to sanitize DOM elements passed via INPLACE mode when the element originates from a different window/realm (e.g., an iframe's contentDocument). A cross-realm instanceof check in the private isNode() function returns false for foreign-realm nodes, causing DOMPurify to stringify the element (yielding '[object HTMLDivElement]'), silently reset INPLACE to false, and return the unsanitized element unchanged with any XSS payloads intact.

— IBM

Affected Software

10 affected componentsFixes available
DOMPurify DOMPurify<=3.3.3
IBM Concert Software<=1.0.0-3.0.0
Cure53 DOMPurify<3.4.4
debian/node-dompurify*
debian/node-dompurify*
debian/node-dompurify<3.4.5+dfsg-1
3.4.5+dfsg-1
debian/node-dompurify<=2.4.1+dfsg+~2.4.0-2+deb12u1, <=2.4.1+dfsg+~2.4.0-2, <=3.1.7+dfsg+~3.0.5-2
3.4.5+dfsg-1
ubuntu/node-dompurify*
ubuntu/node-dompurify*
ubuntu/node-dompurify*

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/node-dompurify to a version that resolves this vulnerability.

    Fixed in 3.4.5+dfsg-1

Event History

Jul 23, 2026
CVE Published
via MITRE·01:16 PM
Data Sourced
via MITRE·01:16 PM
DescriptionSeverityWeakness
Data Sourced
via Red Hat·02:01 PM
DescriptionSeverityAffected Software
Data Sourced
via NVD·02:18 PM
DescriptionSeverityWeakness
Event
via NVD·02:18 PM
Exploit Published
via CISA·03:46 PM
Jul 24, 2026
Updated
via MITRE·09:35 PM
Description
Updated
via NVD·10:16 PM
Description
Jul 28, 2026
Data Sourced
via NVD·03:51 PM
Affected Software
Sep 22, 2026
Data Sourced
via IBM·12:00 AM
DescriptionAffected Software
Nov 20, 2026
Updated
via MITRE·02:31 PM
Description
Updated
via NVD·03:17 PM
Description
Nov 25, 2026
Data Sourced
via OSV·09:32 PM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Frequently Asked Questions

1

What is the severity of CVE-2026-65904?

The severity of CVE-2026-65904 is rated as medium with a score of 4.7.

2

What type of vulnerability is identified in CVE-2026-65904?

CVE-2026-65904 is a Cross-Site Scripting (XSS) vulnerability.

3

How do I fix CVE-2026-65904?

To fix CVE-2026-65904, update DOMPurify to version 3.4.4 or later.

4

What is the impact of CVE-2026-65904?

CVE-2026-65904 can lead to XSS attacks when using IN_PLACE mode with content from a different window or realm.

5

Which versions of DOMPurify are affected by CVE-2026-65904?

Versions of DOMPurify earlier than 3.4.4 are affected by CVE-2026-65904.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203