Impact
Grav plugin‑api before version 1.0.15 fails to properly sanitize uploaded files. The sanitizer only checks for the exact 'svg' extension, allowing files with extensions such as '.svgz' or '.xhtml' to bypass filtering. An attacker who can write media through the API can embed executable script payloads in these files. When an administrator or any visitor accesses the uploaded resource, the script runs in the site’s origin, allowing the attacker to execute arbitrary JavaScript in the victim’s browser context.
Affected Systems
The vulnerability affects Grav installations that use the plugin‑api module older than 1.0.15. All users of getgrav and the Grav core that rely on this plugin should verify the plugin version; any release earlier than 1.0.15 remains at risk.
Risk and Exploitability
The CVSS score of 5.1 indicates medium severity. The EPSS score is not available, and the issue is not listed in CISA KEV. Exploitation requires the attacker to possess api.media.write permission to upload a file via the API. Once the file is uploaded, browsing the file triggers the embedded script. Because the attack leverages file‑upload permissions, the exploitation path hinges on configuration and permission management rather than an easy public vector.
OpenCVE Enrichment