Servers and applications
GHSA-f4c2-g57p-vcx9
Anonymous visitors can store script-running pages through a public image upload form on Debian and Ubuntu Apache
- Severity
- High
- Published
- 25 Nov 2026
- Last changed
- 25 Nov 2026
- Added to UpHeron
- 25 Nov 2026
- Fixed in
- 1.7.53.12, 2.2.35
- Sources
- Project advisories (GitHub)
Description
Grav's upload file name check does not refuse the extension var, which Apache on Debian and Ubuntu maps to its type-map handler. A file such as photo.var.jpg is accepted as an image, and Apache then serves it as a type map in which the uploader chooses the Content-Type and the body, so it comes back as an HTML page with script that runs on the site's own origin. An anonymous visitor can do this through any public Form plugin file field at its default settings, including a field limited to image/. A publisher, or an account holding only api.media.write, can do the same through the API plugin. The script runs in the session of anyone who opens the file's URL, including a super admin, who can then be made to create a new super-admin account. The precondition is Apache with AddHandler type-map var, which is the default of the Debian and Ubuntu package and of the php:-apache images built on it. nginx, Caddy, lighttpd and IIS have no type-map handler and are not affected.
Affected software
| Software | Affected versions |
|---|---|
GravServers and applications · github:getgrav/grav |
|
About Grav
free software content management system written in PHP
- Monthly downloads (Packagist)
- 1,832Packagist, 22 Nov 2026
- Total downloads (Packagist)
- 93,086Packagist, 22 Nov 2026
- GitHub stars
- 15,733GitHub, 22 Nov 2026
- Forks
- 1,428GitHub, 22 Nov 2026
- Latest release
- 2.2.32GitHub, 22 Nov 2026
- Released
- 20 Nov 2026GitHub
- License
- MIT LicenseWikidata
- Written in
- PHPWikidata
- First published on GitHub
- 2 Aug 2014GitHub
Vulnerabilities in Grav
- In our list
- 160
- Published in the last 12 months
- 131
- Critical, last 12 months
- 9
- High, last 12 months
- 86
- Known exploited
- 0
- GHSA-c76m-5vv2-6cmhAccount creators can take over existing accounts through a front-end Flex account formMedium 25 Nov 2026
- GHSA-fhgv-f82r-jm2pRead-only user managers can read not-yet-hashed account passwordsHigh 25 Nov 2026
- GHSA-q3hm-3pg3-x54rPage editors can still overwrite pages their page permissions deny through Flex pages formsMedium 25 Nov 2026
- GHSA-f839-hcfg-jjpwPublishers can overwrite pages their page permissions deny through the page language on multi-language sitesMedium 25 Nov 2026
- GHSA-m5v2-xm86-jpw7User managers can delete any server file through an account's avatar and take over the siteHigh 25 Nov 2026
- GHSA-535p-q4f5-hc5cPublishers can capture the session of a signed-in admin who uploads a file through their formHigh 25 Nov 2026
References
- GitHub Advisory Database https://github.com/advisories/GHSA-f4c2-g57p-vcx9
- github.com https://github.com/getgrav/grav/security/advisories/GHSA-f4c2-g57p-vcx9