# CVE-2019-18857: XSS in enshrined/svg-sanitize due to mishandled script and data values in attributes

- Severity: High 7.5 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/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): 1.04%, higher than 64% of CVEs (2026-12-01)
- Published: 2019-11-11T14:34:59.000Z
- Modified: 2026-06-17T02:25:28.893Z
- Also known as: GHSA-gf8j-v8x5-h9qp
- Weaknesses: CWE-79
- Assigned by: mitre

## Description

darylldoyle svg-sanitizer before 0.12.0 mishandles script and data values in attributes, as demonstrated by unexpected whitespace such as in the javascript&#9;:alert substring.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- enshrined/svg-sanitize (Packagist): before 0.12.0
- svg-sanitizer_project svg-sanitizer: before 0.12.0

## Every score

- GitHub: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N`
- NVD: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N`
- NVD: CVSS:2.0 5.0 Medium `AV:N/AC:L/Au:N/C:N/I:P/A:N`

## References

- <https://github.com/darylldoyle/svg-sanitizer/commit/51ca4b713f3706d6b27769c6296bbc0c28a5bbd0> (patch, third-party-advisory, web)
- <https://github.com/darylldoyle/svg-sanitizer/compare/0.11.0...0.12.0> (third-party-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2019-18857> (advisory)
- <https://github.com/darylldoyle/svg-sanitizer> (package)

## Sources

- CVE List: [CVE-2019-18857](https://www.cve.org/CVERecord?id=CVE-2019-18857), CVE Terms of Use, modified 2024-08-05
- GitHub Advisory Database: [GHSA-gf8j-v8x5-h9qp](https://github.com/advisories/GHSA-gf8j-v8x5-h9qp), CC-BY-4.0, modified 2023-11-08
- NVD: [CVE-2019-18857](https://nvd.nist.gov/vuln/detail/CVE-2019-18857), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2019-18857 · Whole record: https://cve.day/CVE-2019-18857.json · Rebuilt by cve.day 2026-11-25T22:57:47.880Z
