# CVE-2026-66010: DOMPurify before 3.4.12 Hook Bypass via CUSTOM_ELEMENT_HANDLING

> Attackers can bypass DOMPurify hooks to preserve malicious attributes on custom elements, enabling second-order XSS in applications using this library.

- **Severity:** Medium 5.1 (`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`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** A user has to click or open something
- **Fix available:** Yes
- **Published:** 24 Jul 2026
- **Updated:** 17 Sep 2026
- **Also known as:** CLEANSTART-2026-DT43318, CLSA-2026-1784769541, CLSA-2026-1784769611, CLSA-2026-1784943203, CLSA-2026-1784943304, CLSA-2026-1791798931, CLSA-2026-1791806751, CLSA-2026-1791815045, CLSA-2026-1791821569, CLSA-2026-1791825656, CLSA-2026-1791849797, CLSA-2026-1792163693, DEBIAN-CVE-2026-66010, ECHO-6d8a-f8d5-1592, GHSA-c2j3-45gr-mqc4, MINI-2q3p-jm9x-mr5x, MINI-4f52-vhqf-5r52, MINI-5xmq-cq7r-7mj3, MINI-64f7-pjrw-vq3g, MINI-6jf5-ww9m-7ghr, MINI-f5x3-jgp4-mq94, MINI-gj9x-cxcc-g47g, MINI-jcrc-jmg9-jfrq, MINI-jh25-2g4m-jh7r, MINI-mr5w-7x86-q5qm, MINI-p659-p632-r99v, MINI-pgg4-qcxc-6cww, MINI-v954-762f-f84c, MINI-w4w6-3pv4-g73g, MINI-w96x-c222-32jh, MINI-wr29-r6p4-45g7, MINI-xgvg-59c9-9vjh, MINI-xwff-gxxv-wc9m, UBUNTU-CVE-2026-66010

## What is CVE-2026-66010?

CVE-2026-66010 is a medium-severity cross-site scripting vulnerability in cure53 DOMPurify, published on 24 Jul 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.

### Official description

DOMPurify before 3.4.12 fails to execute afterSanitizeElements hook for custom elements allowed via CUSTOM_ELEMENT_HANDLING.tagNameCheck, allowing attributes to bypass application security policies. Attackers can preserve sensitive attributes on custom elements that later re-inject them into innerHTML sinks, creating second-order XSS gadgets.

Weakness: CWE-79 (Improper Neutralization of Input During Web Page Generation)

## Which versions are affected by CVE-2026-66010?

2 open source packages ship an affected version, including dompurify. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `dompurify` | npm | All versions | 3.4.12 |
| `dompurify` | npm | All versions | 3.4.12 |

Products: Cure53 Dompurify.

## How do I fix CVE-2026-66010?

Upgrade dompurify to 3.4.12 or later.

## Is CVE-2026-66010 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-66010 exists.

## Other vulnerabilities in cure53 DOMPurify

- [CVE-2024-47875](https://insights.sbomify.com/CVE-2024-47875/): DOMPurify nesting-based mXSS (critical 10.0)
- [CVE-2024-48910](https://insights.sbomify.com/CVE-2024-48910/): DOMPurify vulnerable to tampering by prototype polution (critical 9.1)
- [CVE-2026-47423](https://insights.sbomify.com/CVE-2026-47423/): DOMPurify XSS via `selectedcontent` re-clone (high 8.2)
- [CVE-2024-45801](https://insights.sbomify.com/CVE-2024-45801/): Tampering by prototype polution in DOMPurify (high 7.3)
- [CVE-2026-49978](https://insights.sbomify.com/CVE-2026-49978/): DOMPurify IN_PLACE Sanitization Bypass via Attached Shadow Root Inside <template>.content (medium 6.3)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-66010 and fix it if it is affected.

What it is: CVE-2026-66010 is a medium-severity cross-site scripting vulnerability in cure53 DOMPurify, published on 24 Jul 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.
Exploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-66010 exists.

Affected packages and fixed versions:
- dompurify (npm): affected all versions; fixed in 3.4.12
- dompurify (npm): affected all versions; fixed in 3.4.12

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2026-66010/ (Markdown: https://insights.sbomify.com/CVE-2026-66010/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-66010
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-66010
- OSV: https://osv.dev/vulnerability/CVE-2026-66010

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-66010/
Summaries are generated and may contain mistakes; the official description above is the record.
