Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
ReconContent editor authenticates to Grav admin panel
-
DeliveryCrafts Markdown image URL with CSS payload in resize() parameters
-
ExploitSaves page, persisting injected CSS in flat-file content store
-
InstallAdmin or reviewer opens page for review
-
C2Grav renders img element with unsanitized style attribute
-
ExecuteInjected CSS overlay displayed in privileged user's browser
-
ImpactUI redress or content-manipulation attack succeeds
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK
2 techniques across 2 tactics: Initial Access, Execution The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Two specific conditions must both be satisfied: (1) The attacker must hold an authenticated content editor account in the Grav CMS with write permission to edit Markdown pages - unauthenticated exploitation is not possible. (2) A higher-privileged user (administrator or reviewer) must actively open or preview the crafted page in their browser session, providing the required passive user interaction. The injection is limited strictly to CSS - JavaScript execution is not achievable through this vector because prior hardening in Grav's media pipeline blocks script-bearing payloads. Installations where all editors are trusted administrators, or where no editorial review workflow exists, are not meaningfully exposed. The attack does not require any non-default configuration of Grav, but does require the existence of a role hierarchy separating content editors from privileged reviewers. |
| Impact | The CVSS 4.0 score of 4.8 reflects the constrained conditions: the attacker must hold a content editor account (PR:H in the vendor-supplied vector, reflecting meaningful write access to the CMS) and a higher-privileged user must actively view the crafted page (UI:P). Real-world risk is meaningful only in multi-tier CMS deployments where untrusted editors exist alongside privileged reviewers or administrators - the classic editorial workflow scenario Grav supports. No KEV listing exists and no EPSS data was provided; no public exploit code has been identified, which aligns with the limited impact class (CSS-only, no JavaScript execution). The C:L/I:L impact ratings are appropriate: the attack enables UI redress and visual deception but cannot directly exfiltrate server-side data or achieve code execution. Environments where all content editors are fully trusted, or where no role separation exists between editors and admins, face negligible realistic exposure despite the network attack vector. |
| Exploit ScenarioDerived | A lower-privileged content editor logs into the Grav admin panel and creates or edits a Markdown page, embedding an image reference with CSS declarations such as position:fixed;top:0;left:0;width:100vw;height:100vh;background:white injected as resize() parameters. When an administrator or reviewer opens the page for approval, the Grav rendering pipeline writes the injected CSS into the img element's style attribute, causing the admin's browser to display a full-viewport overlay that obscures the legitimate admin interface and can redirect clicks to attacker-controlled elements. No public exploit code has been identified at time of analysis. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 08, 2026
Stored CSS injection in Grav CMS (all 2.0 branch releases through 2.0.0-rc.9) lets a lower-privileged content editor manipulate the visual interface seen by higher-privileged administrators and reviewers. The resize() Markdown media action in Excerpts::processMediaActions() writes caller-controlled values directly into rendered img style attributes without sanitization, despite prior hardening that blocked the ?style= and attribute() vectors. An attacker with editorial access can store a crafted image URL with semicolon-delimited CSS declarations that render a full-viewport overlay when a privileged user views the page, enabling UI redress and content-manipulation attacks. No public exploit has been identified at time of analysis; the vendor-confirmed fix is Grav 2.0.0.
RemediationAI
Upgrade to Grav 2.0.0, which is confirmed by the vendor as the fixed release (GitHub Security Advisory GHSA-ffmg-hfvg-jhg9). The two upstream commits (6582166 and e03d29a) address the missing sanitization in the resize() action's styleAttributes propagation path. If immediate upgrade is not feasible, the most effective compensating control is to restrict Markdown page editing permissions exclusively to fully trusted users, eliminating the lower-privileged editor role that is a prerequisite for exploitation; this has the operational trade-off of collapsing the editorial workflow and requiring administrators to author all content directly. There is no known configuration toggle or WAF rule that can safely block the injection while preserving the resize() media action, because the payload is stored as content rather than delivered via a detectable request parameter.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 2 packages in composer, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Grav is a PHP-based flat-file CMS that processes page content written in Markdown. Its media pipeline supports action modifiers such as resize() applied to image references; these actions are parsed by Excerpts::processMediaActions() and translated into HTML attributes on the rendered img element. The vulnerability arises because the resize() code path was excluded from the sanitization applied to other media action parameters: caller-supplied values flow directly into the styleAttributes of the image object and are serialized into the final style= attribute without encoding or filtering. CWE-79 (Improper Neutralization of Input During Web Page Generation) is the root cause class - the application trusts editor-supplied data as safe CSS content when constructing HTML. The attack does not rely on JavaScript, making it resistant to Content Security Policy rules that block inline scripts while still permitting inline styles.
Know when the next one hits your stack
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N
PR:L because content editor is a low-privilege role, not admin; UI:R and S:C because impact is realized in a different user's browser session.
Primary rating from Vendor (vulncheck).
CVSS VectorVendor: vulncheck
Lifecycle Timeline
1DescriptionCVE.org
Grav before 2.0.0 (affected through 2.0.0-rc.9 and the 2.0 branch) contains a stored CSS injection vulnerability in the Markdown image resize() media action. Prior media hardening rejects direct ?style= payloads and unsafe attribute() fallbacks, but the resize() action in Excerpts::processMediaActions() writes caller-controlled values directly into the image's styleAttributes. A lower-privileged content editor who can edit page Markdown can store a crafted image URL with semicolon-delimited CSS declarations in the resize parameters, which are rendered into the final <img style=...> attribute when a higher-privileged reviewer/admin views the page or preview. This does not require JavaScript execution but enables UI redress/overlay and content-manipulation attacks (e.g., a full-viewport fixed overlay). Fixed in 2.0.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
EUVD-2026-42267
GHSA-4wj4-79rr-pvff
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB