{"id":"CVE-2026-65902","state":"PUBLISHED","title":"DOMPurify before 3.4.7 Hook Mutation Pollution via allowedTags","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.","publishedAt":"2026-07-23T13:16:20.528Z","updatedAt":"2026-10-29T21:16:29.413Z","severity":{"score":5.3,"label":"Medium","version":"4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N","source":"VulnCheck"},"assigner":"VulnCheck","products":["cure53 DOMPurify"],"affected":[{"vendor":"cure53","product":"DOMPurify","packageURL":"pkg:npm/dompurify","defaultStatus":"unaffected","versions":[{"version":"0","status":"affected","lessThan":"3.4.7","versionType":"semver"},{"version":"3.4.7","status":"unaffected","versionType":"semver"}]}],"references":["https://github.com/cure53/DOMPurify/security/advisories/GHSA-76mc-f452-cxcm","https://github.com/cure53/DOMPurify/commit/7996f1dc78eb8b7922388aed75d94a9f8fad9a36","https://www.vulncheck.com/advisories/dompurify-before-hook-mutation-pollution-via-allowedtags"],"weaknesses":["CWE-501"],"ingestedAt":"2026-10-29T23:12:04.845Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/65xxx/CVE-2026-65902.json","commit":"dc7676b3f67d6707e4927968546e7e0125ff7ec7","baselineCommit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-65902","state":"PUBLISHED","datePublished":"2026-07-23T13:16:20.528Z","dateUpdated":"2026-10-29T21:16:29.413Z","assignerShortName":"VulnCheck","assignerOrgId":"83251b91-4cc7-4094-a5c7-464a1b83ea10","dateReserved":"2026-07-23T11:03:13.092Z"},"containers":{"cna":{"title":"DOMPurify before 3.4.7 Hook Mutation Pollution via allowedTags","descriptions":[{"lang":"en","value":"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."}],"affected":[{"vendor":"cure53","product":"DOMPurify","packageURL":"pkg:npm/dompurify","defaultStatus":"unaffected","versions":[{"version":"0","status":"affected","lessThan":"3.4.7","versionType":"semver"},{"version":"3.4.7","status":"unaffected","versionType":"semver"}]}],"references":[{"url":"https://github.com/cure53/DOMPurify/security/advisories/GHSA-76mc-f452-cxcm","name":"GitHub Security Advisory (GHSA-76mc-f452-cxcm)","tags":["vendor-advisory"]},{"url":"https://github.com/cure53/DOMPurify/commit/7996f1dc78eb8b7922388aed75d94a9f8fad9a36","name":"Patch Commit","tags":["patch"]},{"url":"https://www.vulncheck.com/advisories/dompurify-before-hook-mutation-pollution-via-allowedtags","name":"VulnCheck Advisory: DOMPurify before 3.4.7 Hook Mutation Pollution via allowedTags","tags":["third-party-advisory"]}],"metrics":[{"format":"CVSS","cvssV4_0":{"version":"4.0","vectorString":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N","attackVector":"NETWORK","attackComplexity":"LOW","attackRequirements":"NONE","privilegesRequired":"NONE","userInteraction":"PASSIVE","vulnConfidentialityImpact":"LOW","vulnIntegrityImpact":"LOW","vulnAvailabilityImpact":"NONE","subConfidentialityImpact":"LOW","subIntegrityImpact":"LOW","subAvailabilityImpact":"NONE","baseScore":5.3,"baseSeverity":"MEDIUM"}},{"format":"CVSS","cvssV3_1":{"version":"3.1","vectorString":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","attackVector":"NETWORK","attackComplexity":"LOW","privilegesRequired":"NONE","userInteraction":"REQUIRED","scope":"CHANGED","confidentialityImpact":"LOW","integrityImpact":"LOW","availabilityImpact":"NONE","baseScore":6.1,"baseSeverity":"MEDIUM"}}],"problemTypes":[{"descriptions":[{"cweId":"CWE-501","lang":"en","description":"Trust Boundary Violation","type":"CWE"}]}],"providerMetadata":{"shortName":"VulnCheck","orgId":"83251b91-4cc7-4094-a5c7-464a1b83ea10","dateUpdated":"2026-10-29T21:16:29.413Z"},"datePublic":"2026-05-26T00:00:00.000Z","cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:a:cure53:dompurify:*:*:*:*:*:*:*:*","versionEndExcluding":"3.4.7"}]}]}],"credits":[{"lang":"en","value":"offset","type":"reporter"}],"x_generator":{"engine":"vulncheck-endgame"}},"adp":[{"title":"CISA ADP Vulnrichment","references":[{"url":"https://github.com/cure53/DOMPurify/security/advisories/GHSA-76mc-f452-cxcm","tags":["exploit"]}],"metrics":[{"other":{"type":"ssvc","content":{"timestamp":"2026-07-23T13:58:18.807154Z","id":"CVE-2026-65902","options":[{"Exploitation":"poc"},{"Automatable":"no"},{"Technical Impact":"partial"}],"role":"CISA Coordinator","version":"2.0.3"}}}],"providerMetadata":{"shortName":"CISA-ADP","orgId":"134c704f-9b21-4f2e-91b3-4a467353bcc0","dateUpdated":"2026-07-23T13:58:32.945Z"}}]}}}