{"answers":{"affected":"2 open source packages ship an affected version, including rhukster/dom-sanitizer.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-40301 exists.","fix":"Upgrade rhukster/dom-sanitizer to 1.0.10 or later.","what":"CVE-2026-40301 is a medium-severity cross-site scripting vulnerability in rhukster dom-sanitizer, published on 17 Apr 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2026-40301 and fix it if it is affected.\n\nWhat it is: CVE-2026-40301 is a medium-severity cross-site scripting vulnerability in rhukster dom-sanitizer, published on 17 Apr 2026. An attacker can exploit it over the internet without logging in, and only if a user opens a file or follows a link.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-40301 exists.\n\nAffected packages and fixed versions:\n- rhukster/dom-sanitizer (Packagist): affected all versions; fixed in 1.0.10\n- rhukster/dom-sanitizer (Packagist): affected all versions; fixed in 1.0.10\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2026-40301/ (Markdown: https://insights.sbomify.com/CVE-2026-40301/index.md)","id":"CVE-2026-40301","markdown":"https://insights.sbomify.com/CVE-2026-40301/index.md","name":"CVE-2026-40301","record":{"aliases":["GHSA-93vf-569f-22cq"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["data_read","security_bypass"],"network_reachable":"yes","non_default_config":false,"product_category":"PHP DOM sanitizer","requires_auth":"none","summary":"An attacker can inject malicious CSS into sanitized SVGs, causing browsers to make unauthorized requests to attacker-controlled servers.","user_interaction":"required","vuln_class":"xss"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[],"cvss":{"score":4.7,"severity":"medium","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:N/A:N","version":"3.1"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"description":"DOMSanitizer is a DOM/SVG/MathML Sanitizer for PHP 7.3+. Prior to version 1.0.10, DOMSanitizer::sanitize() allows \u003cstyle\u003e 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.","ecosystems":["Packagist"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"weaponised"},"has_fix":true,"headline":"rhukster/dom-sanitizer: SVG \u003cstyle\u003e tag allows CSS injection via unfiltered url() and @import directives","id":"CVE-2026-40301","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Packagist","product":null,"products":[],"type":"xss","year":"2026"},"n_packages":2,"n_references":3,"next":{"headline":"zrok has reflected XSS in GitHub OAuth callback via unsanitized refreshInterval error rendering","id":"CVE-2026-40302"},"packages":[{"ecosystem":"Packagist","fixed":["1.0.10"],"introduced":["0"],"last_affected":[],"package":"rhukster/dom-sanitizer","purl":null,"source":"GHSA-93vf-569f-22cq"},{"ecosystem":"Packagist","fixed":["1.0.10"],"introduced":["0"],"last_affected":[],"package":"rhukster/dom-sanitizer","purl":"pkg:composer/rhukster/dom-sanitizer","source":"GHSA-93vf-569f-22cq"}],"prev":{"headline":"Zulip: Message edit history visible in \"moves only\" policy through /api/v1/messages/{id}/history","id":"CVE-2026-40300"},"products":["dom-sanitizer"],"published":"2026-04-17","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"partial"},"state":"PUBLISHED","updated":"2026-04-20","vendors":["rhukster"]},"summary":"An attacker can inject malicious CSS into sanitized SVGs, causing browsers to make unauthorized requests to attacker-controlled servers.","url":"https://insights.sbomify.com/CVE-2026-40301/"}