Stored XSS via DTD entity collision in enshrined/svg-sanitize
Key facts
- Attack vector
- Network
- Privileges required
- Low
- User interaction
- Required
- Attack complexity
- Low
- Impact type
- Cross-site scripting
- Confidentiality · integrity · availability
- Low · Low · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and GitHub. Impact type from CWE-79.
Summary
The enshrined/svg-sanitize Packagist package before 1.0.0 and the darylldoyle svg-sanitizer before 1.0.0 are affected. The href safety check validates a value after DTD entity expansion, but the output keeps the original entity reference, which HTML rendering later decodes into a javascript: URL (CWE-79). A remote attacker with low privileges can cause script to run in the embedding page's origin when a user activates the link in an SVG that the application embeds inline.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
Description from the CNA
savg-sanitizer is a PHP SVG/XML sanitizer. Prior to 1.0.0, svg-sanitizer's isHrefSafeValue() validates an SVG href after XML DTD entity expansion, but saveXML() serializes the original entity reference after removing the DTD declaration. A crafted entity such as Tab can appear to the sanitizer as a safe fragment prefix while HTML5 Named Character Reference resolution during inline HTML rendering later converts the surviving reference to whitespace, exposing a javascript: URL. When an application embeds the sanitized SVG inline, a user who activates the link can cause script to execute in the embedding page's origin. This issue is fixed in version 1.0.0.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| darylldoyle | svg-sanitizer | before 1.0.0 | 1.0.0 | Patch available | CNA |
| — | enshrined/svg-sanitize (Packagist) | before 1.0.0 | 1.0.0 | Patch available | GHSA-9rjx-3jch-6vjf |
- svg-sanitizer Vendordarylldoyle Affected before 1.0.0 Fixed in 1.0.0 Patch available CNA
- enshrined/svg-sanitize (Packagist) Vendor— Affected before 1.0.0 Fixed in 1.0.0 Patch available GHSA-9rjx-3jch-6vjf
Remediation
Upgrade enshrined/svg-sanitize to version 1.0.0. The sources list no fixed version for svg-sanitizer.
Written with Claude Haiku 5.5 from the sources below · 2026-10-29
- Fix · CNA svg-sanitizer (darylldoyle) Fixed in 1.0.0
- Fix · GHSA-9rjx-3jch-6vjf enshrined/svg-sanitize (Packagist) Fixed in 1.0.0 Advisory →
Timeline
- 2026-10-08 Threatist record created from CVE-2026-107380
- 2026-10-09 Alias added: GHSA-9rjx-3jch-6vjf
- 2026-10-09 Fix available: Packagist/enshrined/[email protected] · GHSA-9rjx-3jch-6vjf
- 2026-10-09 CVSS score added · GHSA-9rjx-3jch-6vjf
- 2026-10-09 Weakness changed · GHSA-9rjx-3jch-6vjf
- 2026-10-09 5 new references · GHSA-9rjx-3jch-6vjf
- 2026-10-10 CISA SSVC decision points changed
- 2026-10-10 Priority changed: MEDIUM → LOW
References
More darylldoyle vulnerabilities
- TI-2026-81116 Quadratic CPU exhaustion in svg-sanitizer PHP tag stripping CVSS 4.0HIGH 8.7
- TI-2026-84327 svg-sanitizer ReDoS and Fail-Open via image-set CSS Stripping CVSS 4.0HIGH 8.2
- TI-2026-74075 Mixed-case xlink:HrEf bypasses use nesting limit in svg-sanitizer CVSS 3.1MEDIUM 6.5
- TI-2026-69645 Denial of service in enshrined/svg-sanitize via crafted SVG DTD CVSS 3.1MEDIUM 6.5
- TI-2026-84328 Incomplete url() filtering in svg-sanitizer allows remote URL requests CVSS 4.0MEDIUM 5.3
- TI-2026-81115 darylldoyle svg-sanitizer CSS Injection and Remote Reference Bypass CVSS 4.0MEDIUM 5.1
Sources
- CVE-2026-107380 · CVE Program
- CVE-2026-107380 · NVD
- FIRST EPSS
- GHSA-9rjx-3jch-6vjf · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences