Skip to content
OpenAdvisories
Medium · 4.7 CVE-2026-40301 EUVD-2026-23545GHSA-93vf-569f-22cq

rhukster/dom-sanitizer: SVG <style> tag allows CSS injection via unfiltered url() and @import directives

Published Apr 17, 2026 · Updated Apr 20, 2026 · Assigned by GitHub_M

Description

DOMSanitizer is a DOM/SVG/MathML Sanitizer for PHP 7.3+. Prior to version 1.0.10, DOMSanitizer::sanitize() allows <style> elements in SVG content but never inspects their text content. CSS url() references and @import rules pass through unfiltered, causing the browser to issue HTTP requests to attacker-controlled hosts when the sanitized SVG is rendered. Version 1.0.10 fixes the issue.

Affected products

VendorProductAffectedFixed
rhukster dom-sanitizer < 1.0.10 —

Affected packages

EcosystemPackageAffectedFixedRecord
Packagist rhukster/dom-sanitizer < 1.0.10 1.0.10 GHSA-93vf-569f-22cq

References