CVE-2025-66298
JSON

7.7high

Grav is vulnerable to Server-Side Template Injection (SSTI) via Forms

Severity
7.7high CVSS:4.0 by GitHub_M
Exploit likelihood
0.41% (higher than 37% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
GitHub_M
Also known as
GHSA-8535-hvm8-2hmv

Description

Grav is a file-based Web platform. Prior to 1.8.0-beta.27, having a simple form on site can reveal the whole Grav configuration details (including plugin configuration details) by using the correct POST payload to exploit a Server-Side Template (SST) vulnerability. Sensitive information may be contained in the configuration details. This vulnerability is fixed in 1.8.0-beta.27.

Affected

Product or packageVersionsReported by
getgrav grav< 1.8.0-beta.27, before 1.8.0, 1.8.0CVE List, NVD
getgrav/grav (Packagist)before 1.8.0-beta.27GitHub Advisory Database

All scores

GitHub_M7.7high CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:P
GitHubhigh CVSS:4.0CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:P
NVD7.5high CVSS:3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Classification

CWE-1336

SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial.

What each source says

CVE List

Grav is a file-based Web platform. Prior to 1.8.0-beta.27, having a simple form on site can reveal the whole Grav configuration details (including plugin configuration details) by using the correct POST payload to exploit a Server-Side Template (SST) vulnerability. Sensitive information may be contained in the configuration details. This vulnerability is fixed in 1.8.0-beta.27.

GitHub Advisory Database
Summary

Having a simple form on site can reveal the whole Grav configuration details (including plugin configuration details) by using the correct POST payload. Sensitive information may be contained in the configuration details.

PoC

Create a simple form with two fields, 'registration-number' and 'hp'. Add a submit button and set the method to POST(screenshot attached below). Form name set to 'hero-form'. Send a POST request with the following payload and you will notice a response with a php array listing the whole Grav configuration details - including plugins(screenshot attached).

registration-number:d643aaaa

hp:vJyifp

form-name:hero-form

unique_form_id:{{var_dump(_context|slice(0,7))}}

Screenshot 2025-03-25 at 7 26 02 AM

Screenshot 2025-03-25 at 7 22 58 AM

Impact

Server-Side Template (SST) vulnerability. The vulnerability affects the latest Grav version as of 25th of Match 2025 (1.7.48) with all plugins installed (including forms plugin v.7.4.2) to their latest versions as well.

NVD (es)

Grav es una plataforma web basada en archivos. Versiones anteriores a 1.8.0-beta.27, tener un formulario simple en el sitio puede revelar todos los detalles de configuración de Grav (incluidos los detalles de configuración del plugin) mediante el uso de la carga útil POST correcta para explotar una vulnerabilidad de plantilla del lado del servidor (SST). Información sensible puede estar contenida en los detalles de configuración. Esta vulnerabilidad está corregida en 1.8.0-beta.27.

References

Sources

SourceRecordLicence
CVE ListCVE-2025-66298 changed 2025-12-02CVE Terms of Use
GitHub Advisory DatabaseGHSA-8535-hvm8-2hmv changed 2026-09-10CC-BY-4.0
NVDCVE-2025-66298 changed 2026-09-26Public domain