# CVE-2024-28118: Grav vulnerable to Server Side Template Injection (SSTI)

- Severity: High 8.8 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.22%, higher than 69% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2024-03-21T21:55:11.788Z
- Modified: 2026-09-10T03:50:10.916Z
- Also known as: GHSA-r6vw-8v8r-pmp4
- Weaknesses: CWE-94
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: GitHub_M

## Description

Grav is an open-source, flat-file content management system. Prior to version 1.7.45, due to the unrestricted access to twig extension class from Grav context, an attacker can redefine config variable. As a result, attacker can bypass a previous SSTI mitigation. Twig processing of static pages can be enabled in the front matter by any administrative user allowed to create or edit pages. As the Twig processor runs unsandboxed, this behavior can be used to gain arbitrary code execution and elevate privileges on the instance. Version 1.7.45 contains a fix for this issue.

(As written by CVE List.)

## Affected

- getgrav grav: < 1.7.45; before 1.7.45
- getgrav/grav (Packagist): before 1.7.45

## Every score

- GitHub_M: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- GitHub: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://github.com/getgrav/grav/security/advisories/GHSA-r6vw-8v8r-pmp4> (exploit, vendor-advisory, web)
- <https://github.com/getgrav/grav/commit/de1ccfa12dbcbf526104d68c1a6bc202a98698fe> (patch, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-28118> (advisory)
- <https://github.com/getgrav/grav> (package)

## Sources

- CVE List: [CVE-2024-28118](https://www.cve.org/CVERecord?id=CVE-2024-28118), CVE Terms of Use, modified 2024-08-02
- GitHub Advisory Database: [GHSA-r6vw-8v8r-pmp4](https://github.com/advisories/GHSA-r6vw-8v8r-pmp4), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2024-28118](https://nvd.nist.gov/vuln/detail/CVE-2024-28118), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-28118 · Whole record: https://cve.day/CVE-2024-28118.json · Rebuilt by cve.day 2026-11-25T22:58:37.826Z
