p PatchFirst

PatchFirst · Aktuelle Sicherheitslücken

dompurify 3.4.7: bekannte Sicherheitslücken

Bekannte Sicherheitslücken für dompurify 3.4.7: 9. Vergleichen Sie die unten genannten Korrekturen mit Ihrer installierten Version.

Sicherheitslücken filtern
Filter zurücksetzen

Sicherheitslücken: 9

  1. GHSA-cg2g-xh64-v4q7

    Kritisch · CVSS 9.2Korrektur verfügbar

    DOMPurify SAFE_FOR_TEMPLATES bypass: split template expressions survive in attached shadow root content on DOM output modes

    ## Summary When DOMPurify is configured with `SAFE_FOR_TEMPLATES: true` together with a DOM-returning mode (`RETURN_DOM: true`, `RETURN_DOM_FRAGMENT: true`, or `IN_PLACE: true`), template expressions such as `{{...}}`, `${...}`, and `<%...%>` survive sanitization inside the text content of an attached shadow root. The post-walk safety net `_scrubTemplateExpressions` (`src/purify.ts:1717`) was extended to recurse into `<template>.content`, but it never recurses into attached shadow roots. An attacker who can supply a DOM node carrying a shadow root (the `IN_PLACE` and shadow-aware `RETURN_DOM` surfaces) can split an expression across text nod

    • Auf 3.4.17 aktualisieren
    Veröffentlicht Aktualisiert
  2. GHSA-mrv2-3pqr-j5jr

    Hoch · CVSS 7.6Korrektur verfügbar

    DOMPurify IN_PLACE: hook that removes a parent or sibling leaves the detached subtree's event handlers armed (incomplete fix for GHSA-p98j-92pf-mc4p)

    ### Summary The 3.4.16 fix for GHSA-p98j-92pf-mc4p only covers a hook that removes the node it was called for. If an `IN_PLACE` hook removes a different node, like the current node's parent or a sibling that has not been visited yet, that subtree is never walked or neutralized. Event handlers in it stay on the elements, and an `<img onerror>` that was already loading fires after `sanitize()` returns. The README says: "Nodes that a hook detaches from the tree ... are treated as removed. In IN_PLACE mode their subtree is neutralized inline, so an `<img onload>` that was already loading when you built the live tree cannot fire after `sanitize(

    • Auf 3.4.17 aktualisieren
    Veröffentlicht Aktualisiert
  3. GHSA-c6gr-qvv4-5v3f

    Nicht bewertetKorrektur verfügbar

    DOMPurify: SMIL attributeName=href guard is skipped when PARSER_MEDIA_TYPE is application/xhtml+xml

    ### Summary DOMPurify drops `attributeName` attributes whose value contains `href`, so an allowed `<animate>` or `<set>` can't rewrite a link's href after sanitizing. The check compares the attribute name after `transformCaseFunc`, and that function doesn't lowercase in XHTML mode. In XHTML the attribute is spelled `attributeName`, so the comparison with `"attributename"` never matches and the guard does nothing. An app that uses `PARSER_MEDIA_TYPE: 'application/xhtml+xml'` and allows `animate` and `attributeName` will keep `<animate attributeName="href" values="x;javascript:alert(1)">`. Clicking the parent link then runs the script. This

    • Auf 3.4.17 aktualisieren
    Veröffentlicht Aktualisiert
  4. CVE-2026-109345

    Mittel · CVSS 5.1EPSS 0,25%Korrektur verfügbar

    DOMPurify before 3.4.16 XSS via IN_PLACE Returned Rawtext Root

    DOMPurify before 3.4.16 contains a cross-site scripting vulnerability that allows attackers to bypass sanitization because IN_PLACE mode returns a force-removed style element whose text content still carries markup. Attackers can supply a style element containing a closing style tag and an img onerror payload, which executes script when the application serializes and re-parses the returned node.

    • Auf 3.4.16 aktualisieren
    Veröffentlicht Aktualisiert
  5. CVE-2026-75838

    Mittel · CVSS 5.1EPSS 0,39%Korrektur verfügbar

    DOMPurify before 3.4.13 Cross-Site Scripting via IN_PLACE hook

    DOMPurify before 3.4.13 contains a cross-site scripting vulnerability in IN_PLACE sanitization where element-removal hooks fail to neutralize detached subtrees. Attackers can supply HTML with event handlers on descendant elements that execute after sanitization completes, even though the returned root appears clean.

    • Auf 3.4.13 aktualisieren
    Veröffentlicht Aktualisiert
  6. CVE-2026-66010

    Mittel · CVSS 5.1EPSS 0,21%Korrektur verfügbar

    DOMPurify before 3.4.12 Hook Bypass via CUSTOM_ELEMENT_HANDLING

    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.

    • Auf 3.4.12 aktualisieren
    Veröffentlicht Aktualisiert
  7. CVE-2026-65900

    Mittel · CVSS 5.1EPSS 0,31%Korrektur verfügbar

    DOMPurify before 3.4.8 Template Expression Injection via RETURN_DOM

    DOMPurify versions >=3.0.0 and before 3.4.8, when configured with SAFE_FOR_TEMPLATES together with a DOM output mode (RETURN_DOM, RETURN_DOM_FRAGMENT, or IN_PLACE), fail to strip template expressions (e.g. ${evil}, {{evil}}, <%evil%>) inside <template> element content. The final normalization/scrub pass (_scrubTemplateExpressions) uses a NodeIterator and node.normalize() that do not descend into template.content, so expressions that only form after adjacent text nodes merge survive sanitization. This bypasses SAFE_FOR_TEMPLATES and can allow a downstream template engine to evaluate attacker-supplied expressions. The string output path is not

    • Auf 3.4.8 aktualisieren
    Veröffentlicht Aktualisiert
  8. CVE-2026-65899

    Mittel · CVSS 5.1EPSS 0,41%Korrektur verfügbar

    DOMPurify before 3.4.9 Trusted Types Policy State Contamination

    DOMPurify 3.0.0 before 3.4.9 does not reset the retained Trusted Types policy when clearConfig() is called, so a DOMPurify instance reused across trust boundaries stays bound to a previously supplied TRUSTED_TYPES_POLICY. A later caller that requests RETURN_TRUSTED_TYPE output receives a TrustedHTML object created by the old (potentially unsafe) policy rather than a clean default, which can lead to script execution at a Trusted Types sink. Passing TRUSTED_TYPES_POLICY: null on the later call also does not clear the retained policy.

    • Auf 3.4.9 aktualisieren
    Veröffentlicht Aktualisiert
  9. CVE-2026-65898

    Mittel · CVSS 5.1EPSS 0,21%Korrektur verfügbar

    DOMPurify before 3.4.11 Permanent Attribute Allowlist Pollution via setConfig

    DOMPurify before 3.4.11 fails to clone the ALLOWED_ATTR allowlist when setConfig() is used with an uponSanitizeAttribute hook, allowing the hook to permanently mutate the shared allowlist. Attackers can register a hook that conditionally allows dangerous attributes like onerror for trusted elements, then submit untrusted content that inherits the polluted allowlist and executes event handlers as stored XSS.

    • Auf 3.4.11 aktualisieren
    Veröffentlicht Aktualisiert

Prüfen Sie Ihren Server

Gleichen Sie Ihren installierten Stack und seine Versionen mit den aktuellen Sicherheitsmeldungen ab.

Prüfen Sie Ihren Server →