{
  "affected": [
    {
      "ranges": [
        {
          "database_specific": {
            "extracted_events": [
              {
                "introduced": "0"
              },
              {
                "fixed": "1.0.3"
              }
            ],
            "source": [
              "AFFECTED_FIELD",
              "DESCRIPTION"
            ]
          },
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "4a5a400b89f38244bf4c958242c557309527bedd"
            }
          ],
          "repo": "https://github.com/getgrav/grav",
          "type": "GIT"
        }
      ]
    }
  ],
  "aliases": [
    "GHSA-7vhm-8x52-2r5p"
  ],
  "database_specific": {
    "cna_assigner": "VulnCheck",
    "cwe_ids": [
      "CWE-79"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/61xxx/CVE-2026-61456.json"
  },
  "details": "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 \u003cobject\u003e/\u003ciframe\u003e), the embedded script executes in their session context, enabling cookie theft and session hijacking.",
  "id": "CVE-2026-61456",
  "modified": "2026-07-15T01:48:59.479008481Z",
  "published": "2026-07-10T13:58:09.670Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/61xxx/CVE-2026-61456.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/getgrav/grav/security/advisories/GHSA-7vhm-8x52-2r5p"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-61456"
    },
    {
      "type": "ADVISORY",
      "url": "https://www.vulncheck.com/advisories/grav-before-stored-xss-via-svg-upload-api"
    }
  ],
  "schema_version": "1.8.0",
  "severity": [
    {
      "score": "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",
      "type": "CVSS_V4"
    }
  ],
  "summary": "Grav before 1.0.3 Stored XSS via SVG Upload API"
}