{"id":"CVE-2026-61456","aliases":["CVE-2026-61456"],"related":[],"kind":"vulnerability","state":"published","title":"Grav before 1.0.3 Stored XSS via SVG Upload API","summary":"The Grav API plugin (getgrav/grav-plugin-api) before 1.0.3 fails to sanitize SVG files uploaded through the POST /api/v1/media endpoint. The HandlesMediaUploads::processUploadedFile() method validates only the file extension and never invokes Security::sanitizeSVG(), so an authenticated attacker with the api.media.write permission can upload an SVG containing arbitrary JavaScript. The file is stored unmodified and served with Content-Type: image/svg+xml; when an administrator opens it in a browser (directly or via <object>/<iframe>), the embedded script executes in their session context, enabling cookie theft and session hijacking.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"The Grav API plugin (getgrav/grav-plugin-api) before 1.0.3 fails to sanitize SVG files uploaded through the POST /api/v1/media endpoint. The HandlesMediaUploads::processUploadedFile() method validates only the file extension and never invokes Security::sanitizeSVG(), so an authenticated attacker with the api.media.write permission can upload an SVG containing arbitrary JavaScript. The file is stored unmodified and served with Content-Type: image/svg+xml; when an administrator opens it in a browser (directly or via <object>/<iframe>), the embedded script executes in their session context, enabling cookie theft and session hijacking.","source":"cvelist"},{"lang":"es","text":"El plugin de API de Grav (getgrav/grav-plugin-api) anterior a la versión 1.0.3 no logra sanear los archivos SVG subidos a través del endpoint POST /api/v1/media. El método HandlesMediaUploads::processUploadedFile() valida solo la extensión del archivo y nunca invoca Security::sanitizeSVG(), por lo que un atacante autenticado con el permiso api.media.write puede subir un SVG que contenga JavaScript arbitrario. El archivo se almacena sin modificar y se sirve con Content-Type: image/svg+xml; cuando un administrador lo abre en un navegador (directamente o a través de [object_tag]/[iframe_tag]), el script incrustado se ejecuta en el contexto de su sesión, lo que permite el robo de cookies y el secuestro de sesión.","source":"nvd"}],"published":"2026-07-10T13:58:09.670Z","modified":"2026-10-25T15:10:00.147Z","severity":{"scorer":"VulnCheck","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N","score":5.1,"rating":"MEDIUM"},"severities":[{"scorer":"VulnCheck","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N","score":5.1,"rating":"MEDIUM"},{"scorer":"VulnCheck","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:L/I:L/A:N","score":4.6,"rating":"MEDIUM"}],"cwes":["CWE-79"],"affected":[{"ranges":[{"type":"semver","introduced":"0","fixed":"1.0.3","status":"affected"},{"type":"semver","version":"1.0.3","status":"unaffected"}],"vendor":"getgrav","product":"grav","source":"cvelist"}],"references":[{"url":"https://github.com/getgrav/grav/security/advisories/GHSA-7vhm-8x52-2r5p","tags":["exploit","vendor-advisory"],"sources":["cvelist","nvd"]},{"url":"https://www.vulncheck.com/advisories/grav-before-stored-xss-via-svg-upload-api","tags":["third-party-advisory"],"sources":["cvelist","nvd"]}],"credits":["alienkeric"],"assigner":"VulnCheck","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"no","technicalImpact":"partial","date":"2026-07-10T14:45:09.952Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-61456","url":"https://www.cve.org/CVERecord?id=CVE-2026-61456","licence":"CVE Terms of Use","modified":"2026-07-10T14:45:32.763Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-61456","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-61456","licence":"Public domain","modified":"2026-10-25T15:10:00.147Z"}],"updatedAt":"2026-11-25T22:59:27.637Z","epss":{"score":0.00172,"percentile":0.06931,"date":"2026-12-01T12:00:22.000Z"}}