CVE-2026-116803: DOMPurify DOM XSS in IN_PLACE hook-detached subtrees

CVE-2026-116803 · Severity: medium · CVSS 6.1 · Published 2026-10-27

DOMPurify is a JavaScript library that sanitizes HTML to prevent cross-site scripting attacks. When an application uses DOMPurify's IN_PLACE mode with custom hooks that remove parent or sibling nodes, event handlers in the detached markup remain active and can execute after sanitization completes, allowing attackers to trigger malicious code like onerror handlers on images.

Technologies: Cure53 DOMPurify. Vendors: Cure53.

Quick answers

Is CVE-2026-116803 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-116803 being exploited in the wild.
How severe is CVE-2026-116803?
Medium severity, with a CVSS score of 6.1, published 27 October 2026.
Which products and versions are affected?
Cure53 DOMPurify before 3.4.17.
Is there a fix for CVE-2026-116803?
Yes: fixed in 3.4.17. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-116803 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-116803?
Check whether you run Cure53 DOMPurify at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • Fixed in: 3.4.17

Technical details

The vulnerability is an incomplete fix in _handleHookDetachedNode() that only detects when a hook removes the current node itself, not when it removes parent or sibling nodes. When a parent or ancestor is removed, the detached subtree becomes unreachable by the walker but is not added to DOMPurify.removed, so event handlers are never stripped. An attacker can craft markup with armed event handlers that fire after sanitize() returns, achieving DOM XSS when the application uses a hook pattern like removing wrapper elements around disallowed content.

Affected products

  • Cure53 DOMPurify before 3.4.17

Timeline

  • 2026-10-12: disclosed
  • 2026-10-27: advisory

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.