CVE-2026-65902: DOMPurify - Stored XSS
- Cve: CVE-2026-65902
- Name: DOMPurify - Stored XSS
- Description: DOMPurify before 3.4.7 passes direct references to the module-level DEFAULT_ALLOWED_TAGS and DEFAULT_ALLOWED_ATTR sets to the uponSanitizeElement and uponSanitizeAttribute hooks via data.allowedTags / data.allowedAttributes when sanitize is called without an explicit cfg.ALLOWED_TAGS / cfg.ALLOWED_ATTR array. A hook that mutates these fields permanently widens the default allow-lists for the lifetime of the DOMPurify instance, so all subsequent default-config sanitize calls inherit the widened defaults and attacker payloads using the poisoned tag/attribute name survive sanitization. removeAllHooks(), clearConfig(), and passing a fresh cfg do not recover the state; only constructing a new DOMPurify instance does.
- Impact: Attackers can bypass sanitization to execute malicious scripts, leading to cross-site scripting attacks.
- Remediation: Update to version 3.4.7 or later.
- Vulnerability type: stored_xss
- Vulnerability impact: stored_xss
- Requirements: Attacker must mutate sanitization hooks to widen allowed tags/attributes
- Labels source: projectdiscovery
- Severity: medium
- Cvss score: 6.1
- Cvss vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
- Epss score: 0.00355
- Epss percentile: 0.29841
- Assignee: [email protected]
- Published at: 2026-07-23T14:18:05Z
- Age in days: 124
- Modified at: 2026-10-29T21:17:29Z
- Patch available: yes
- Public exploits total: 1
- References total: 3
- Products total: 1
- Oss: yes
- Projects total: 1
- Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2026-65902
- Nvd status: modified
- Checked, none or zero: known exploited entries, nuclei templates, public exploits capped, rejected by nvd
- Not known: requirement type, hackerone
Cwe
| Id | Name |
|---|---|
| CWE-501 | Trust Boundary Violation |
Public exploits
| Url | Source | Added date |
|---|---|---|
| https://github.com/cure53/DOMPurify/security/advisories/GHSA-76mc-f452-cxcm | nvd | 2026-07-23 |
References
Same in every row:
- Source: nvd
Products
| Product | Affected | Platform bound | Sources | Url |
|---|---|---|---|---|
| cure53:dompurify | < 3.4.7 | no | nvd | /v1/products/cure53/dompurify |
Projects
| Repository | Link kinds | Indexed | Url |
|---|---|---|---|
| cure53/dompurify | commit, package, security_advisory | yes | /v1/repositories/cure53/dompurify |
Index
- Repositories: 1022
- Repositories high signal: 747
- Packages: 1
Exploitation
- Public exploit: yes
- Public exploit count: 1
- Public exploit first date: 2026-07-23
- Remote: yes
- Checked, none or zero: known exploited, known exploited by, exploitation seen, initial access, authentication required
- Not known: known exploited since, vulncheck known exploited since, nuclei template, initial access since, hackerone reports, exposed hosts