CVE-2025-66294: getgrav grav Code Injection
Vulnerability summary
CVE-2025-66294 is a high (CVSS 8.8) Code Injection vulnerability in getgrav grav. EPSS estimates a 2.82% chance of exploitation in the next 30 days, higher than 86.3% of scored vulnerabilities. 2 public exploits are recorded.
Timeline
- 01-12-2025PublishedVulnerability first disclosed.
- 02-12-2025Last modifiedVulnerability information updated.
Description
Grav is a file-based Web platform. Prior to 1.8.0-beta.27, a Server-Side Template Injection (SSTI) vulnerability exists in Grav that allows authenticated attackers with editor permissions to execute arbitrary commands on the server and, under certain conditions, may also be exploited by unauthenticated attackers. This vulnerability stems from weak regex validation in the cleanDangerousTwig method. This vulnerability is fixed in 1.8.0-beta.27.
CVSS metrics
3 scores · 2 sources · 2 versions- NVDNIST8.7HighCVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
EPSS trend
Probability
2.82%
Chance of exploitation in the next 30 days
Percentile
86%
Versus all other CVEs
30-day change
0.00 pp
From 2.82% on 20-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
2 foundGrav
Maturity: poc
Grav CMS Twig SSTI Authenticated Sandbox Bypass RCE
exploit/multi/http/grav_twig_ssti_sandbox_bypass_rce
Maturity: weaponized
Weaknesses
CWE · root cause- CWE-94Improper Control of Generation of Code ('Code Injection')The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.
- CWE-1336Improper Neutralization of Special Elements Used in a Template EngineThe product uses a template engine to insert or process externally-influenced input, but it does not neutralize or incorrectly neutralizes special elements or syntax that can be interpreted as template expressions or other code directives when processed by the engine.
Affected systems
Getgrav1 product
- grav< 1.8.0-beta.27 | ≥ 1.7.48, < 1.8.0 | 1.8.0:beta1 | 1.8.0:beta10 | 1.8.0:beta11 | 1.8.0:beta12 | 1.8.0:beta13 | 1.8.0:beta14 | 1.8.0:beta15 | 1.8.0:beta16 | 1.8.0:beta17 | 1.8.0:beta18 | 1.8.0:beta19 | 1.8.0:beta2 | 1.8.0:beta20 | 1.8.0:beta21 | 1.8.0:beta22 | 1.8.0:beta23 | 1.8.0:beta24 | 1.8.0:beta25 | 1.8.0:beta26 | 1.8.0:beta3 | 1.8.0:beta4 | 1.8.0:beta5 | 1.8.0:beta6 | 1.8.0:beta7 | 1.8.0:beta8 | 1.8.0:beta9
1 vendor · 1 product
References
2 links- github.com/getgrav/grav/security/advisories/GHSA-662m-56v4-3r8fX Refsource CONFIRMExploitVendor Advisory