Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessAuthenticate as low-privilege editor via API
-
DeliverySend PATCH /pages with onerror= payload in Markdown content
-
ExploitPayload stored without XSS sanitization
-
ExecutionVictim admin or visitor loads poisoned page
-
PersistInjected script executes in victim's browser
-
ImpactSession cookie or credential exfiltrated
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 | Exploitation requires an authenticated session with at least editor-level (non-superadmin) privileges on the target Grav installation - unauthenticated access is not sufficient per the PR:L CVSS metric. The grav-plugin-api (Admin2) plugin must be installed and the REST API must be reachable over the network. The targeted content field must not have xss_check: false set in its blueprint definition; fields that explicitly opt out of XSS checking are trusted by design and remain unaffected by this fix. A victim user (administrator or visitor) must subsequently load the page containing the injected payload - stored XSS does not execute until the poisoned page is rendered in a browser. Deployments not using the grav-plugin-api REST plugin, or those restricting API write access exclusively to superadmin accounts, are not exposed to this attack path. |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:L/UI:P) scores this at 5.1 (Medium), accurately reflecting two key mitigating factors: exploitation requires a valid low-privileged editor account (PR:L) and a victim must passively load the poisoned page (UI:P). The stored nature of this XSS significantly elevates real-world impact compared to reflected variants - a single successful PATCH request persists the payload across every subsequent page view, potentially targeting administrator sessions persistently. The subsequent-system impact dimensions (SC:L/SI:L) acknowledge cross-session risk such as session cookie theft or admin account takeover. No EPSS score was provided in the input data, leaving probabilistic exploitation likelihood unquantified. No CISA KEV listing exists. However, publicly available exploit code exists: a concrete PoC payload is documented in both the Fluid Attacks advisory and the vendor's regression test. For multi-tenant CMS deployments where untrusted or external contributors hold editor-level API access, this represents a meaningful privilege-escalation path to admin compromise and warrants prioritised patching above its medium base score. |
| Exploit ScenarioDerived | An attacker with a valid editor-level account authenticates to the Grav REST API and issues a PATCH /pages request with a Markdown content body containing a payload such as <img src=x onerror=alert(document.cookie)>; because validateChangedFields() omits the checkSafety() call, the payload is written to the flat-file store without sanitization. When an administrator or site visitor subsequently loads the affected page, the injected handler fires in their browser session, enabling session cookie exfiltration, admin credential theft, or further payload staging. A concrete PoC payload is publicly documented in the Fluid Attacks advisory and the vendor's regression test suite. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jun 18, 2026
Stored XSS in Grav CMS's grav-plugin-api (Admin2) allows a low-privileged editor to persist malicious JavaScript in page content via the PATCH /pages API endpoint, which then executes in any administrator's or visitor's browser when the affected page is loaded. The root cause is that the API's partial-field validation path (validateChangedFields()) ran only type and required-field checks but omitted the XSS safety gate (Validation::checkSafety()), a check the classic Admin interface correctly enforced - creating a trust-boundary bypass exclusive to the REST API path. Publicly available exploit code exists via the Fluid Attacks advisory and the vendor's own regression test suite; no active exploitation (CISA KEV) has been confirmed.
RemediationAI
Upstream fix available (PR/commit); released patched version not independently confirmed. Apply patch commit b8ca62eddb7dbea92075a78b1c0a507f03d66d4a from https://github.com/getgrav/grav-plugin-api/commit/b8ca62eddb7dbea92075a78b1c0a507f03d66d4a, which adds Validation::checkSafety() to AbstractApiController::validateChangedFields() and closes the trust-boundary gap. Monitor https://github.com/getgrav/grav-plugin-api and the security advisory at https://github.com/getgrav/grav/security/advisories/GHSA-5wc5-7v9g-f7v6 for a tagged release incorporating this fix. If immediate patching is not feasible, restrict API access to the PATCH /pages and PATCH /accounts endpoints to superadmin-level users only via network ACL or application-layer authentication controls, eliminating the attack surface for non-superadmin editors; the trade-off is that any automation or integrations relying on editor-level API writes will break. Alternatively, disable the grav-plugin-api plugin entirely if REST API access is not operationally required, accepting that all Admin2 API integrations will cease to function. Do not rely solely on a WAF-based XSS filter as a compensating control, as Markdown-context bypass payloads are well-documented and evasion is straightforward.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 1 package in euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Grav CMS is a flat-file PHP CMS; the affected component is grav-plugin-api (Admin2), identified by CPE cpe:2.3:a:grav:grav-plugin-api:*:*:*:*:*:*:*:*. The vulnerability resides in AbstractApiController::validateChangedFields() in classes/Api/Controllers/AbstractApiController.php, which handles partial-field delta submissions for HTTP PATCH requests to the /pages and /accounts endpoints. The classic Admin interface runs the full blueprint validator, which calls Validation::checkSafety() per field - invoking Security::detectXss() - before persisting content. The API path called only Validation::validate() for type and required checks, leaving the XSS safety gate entirely absent. CWE-79 (Improper Neutralization of Input During Web Page Generation) is the root cause class: unsanitized HTML event handlers such as onerror= attributes embedded in Markdown content fields (type: markdown, validated as textarea) were stored verbatim and later rendered in victim browsers. The fix adds Validation::checkSafety() calls within validateChangedFields() and honours the existing security.xss_whitelist (admin.super) and per-field xss_check: false blueprint settings, maintaining behavioural parity with the classic admin.
Know when Grav gets its next vulnerability
- 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:L/UI:P/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N
Editor-level authentication required (PR:L), victim must load page (UI:R), stored payload persists across sessions with scope change (S:C), no availability impact.
Primary rating from Vendor (Fluid Attacks).
CVSS VectorVendor: Fluid Attacks
DescriptionCVE.org
Grav 2.0.0-rc.9 with Admin2 2.0.0-rc.14 contains a stored cross-site scripting (XSS) vulnerability in the Admin2 Pages API save flow.
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.
Server-side template injection (SSTI) in Grav (getgrav/grav) prior to 1.8.0-beta.27 allows an authenticated attacker hol
Broken access control in Grav CMS (CWE-285) before 1.8.0-beta.27 lets an authenticated editor-level user escalate their
A Remote Code Execution (RCE) vulnerability in Grav CMS v1.7.48 allows an authenticated admin to upload a malicious plug
Grav is a file-based Web platform. Rated critical severity (CVSS 9.9), this vulnerability is remotely exploitable, low a
GravCMS 1.10.7 allows unauthenticated remote attackers to write arbitrary YAML configuration files, leading to full serv
Remote code execution in Grav CMS 2.0.4 (fixed in 2.0.7) lets an authenticated user holding the admin.pages or api.pages
Remote code execution in Grav CMS before 2.0.15 allows attackers holding page-edit or blueprint-config privileges to wri
Vertical privilege escalation in Grav CMS before 2.0.14 lets a delegated administrator holding only the admin.users perm
Stored cross-site scripting in Grav CMS before 2.0.15 lets authenticated editors smuggle JavaScript event handlers past
Server-side request forgery (SSRF) in Grav CMS versions prior to 1.7.49.5 allows remote authenticated attackers to make
Grav is a file-based Web platform. Prior to 1.8.0-beta.27, Grav CMS is vulnerable to a Server-Side Template Injection (S
Remote code execution in Grav CMS before 2.0.13 allows authenticated low-privilege users to plant and execute arbitrary
EUVD-2026-37916
GHSA-pfvx-ccc8-f3hr
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB