# CVE-2026-107380: enshrined/svg-sanitize: Stored XSS via DTD Entity / HTML5 Named Character Reference Collision

- Severity: Medium 5.4 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.25%, higher than 18% of CVEs (2026-12-01)
- Published: 2026-10-08T18:06:14.107Z
- Modified: 2026-10-09T16:17:22.457Z
- Also known as: GHSA-9rjx-3jch-6vjf
- Weaknesses: CWE-79
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

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.

(As written by CVE List.)

## Affected

- darylldoyle svg-sanitizer: < 1.0.0
- enshrined/svg-sanitize (Packagist): before 1.0.0

## Every score

- GitHub_M: CVSS:3.1 5.4 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`
- GitHub: CVSS:3.1 5.4 Medium `CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N`

## References

- <https://github.com/darylldoyle/svg-sanitizer/security/advisories/GHSA-9rjx-3jch-6vjf> (web)
- <https://github.com/darylldoyle/svg-sanitizer/commit/23877db7e76f1e1df5c3e65ab30239219c3d2867> (web)
- <https://github.com/darylldoyle/svg-sanitizer/releases/tag/1.0.0> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-107380> (advisory)
- <https://github.com/darylldoyle/svg-sanitizer> (package)

## Sources

- CVE List: [CVE-2026-107380](https://www.cve.org/CVERecord?id=CVE-2026-107380), CVE Terms of Use, modified 2026-10-09
- GitHub Advisory Database: [GHSA-9rjx-3jch-6vjf](https://github.com/advisories/GHSA-9rjx-3jch-6vjf), CC-BY-4.0, modified 2026-10-08
- NVD: [CVE-2026-107380](https://nvd.nist.gov/vuln/detail/CVE-2026-107380), Public domain, modified 2026-10-09

---

Page: https://cve.day/CVE-2026-107380 · Whole record: https://cve.day/CVE-2026-107380.json · Rebuilt by cve.day 2026-11-25T22:59:43.200Z
