A Leader in the 2026 Gartner® Magic Quadrant™ for Endpoint Protection. Six years running.Six years. Gartner® Magic Quadrant™ Leader.Find Out Why
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-42845

CVE-2026-42845: Grav Form Plugin Auth Bypass Vulnerability

CVE-2026-42845 is an authentication bypass flaw in Grav Form Plugin that allows unauthenticated attackers to overwrite page content via file upload. This article covers technical details, affected versions, and mitigation.

Published: May 18, 2026

CVE-2026-42845 Overview

CVE-2026-42845 affects the Grav form plugin, which adds form creation and handling capabilities to the Grav flat-file content management system (CMS). Versions prior to 9.1.0 contain an unauthenticated page-content overwrite flaw exploitable through the public file upload handler. An attacker can submit a crafted filename parameter in a multipart POST request to traverse outside the intended upload destination and overwrite the page's own .md source file. Combined with a process: save action and a permissive accept policy, the attacker can pivot to super-admin access. The issue is tracked under GHSA-w4rc-p66m-x6qq and is classified as [CWE-73] External Control of File Name or Path.

Critical Impact

Unauthenticated attackers can overwrite arbitrary page-content files on a vulnerable Grav site and escalate to super-admin privileges.

Affected Products

  • Grav CMS form plugin versions prior to 9.1.0
  • Grav sites with publicly reachable forms accepting file uploads
  • Configurations using the default destination: self@ upload target

Discovery Timeline

  • 2026-05-11 - CVE-2026-42845 published to NVD
  • 2026-05-12 - Last updated in NVD database

Technical Details for CVE-2026-42845

Vulnerability Analysis

The Grav form plugin exposes a public upload endpoint that processes multipart form submissions. The handler in classes/Form.php accepted the client-supplied filename POST field verbatim without stripping path components. When the form's destination was set to self@, uploads landed alongside the page's own Markdown source. A request containing a filename such as item.md could therefore overwrite the page file itself.

Grav pages can declare frontmatter that defines forms, including a process: block. By rewriting a page to include a process: save action targeting an admin-controlled file, an unauthenticated attacker can plant credentials or modify the super-admin account on the next form submission. The flaw chains a path component injection with Grav's flat-file storage model to escalate from file upload to administrative takeover.

Root Cause

The upload handler trusted the POST-supplied filename value and only enforced a configurable dangerous-extensions blocklist. Page-content extensions such as md, yaml, yml, json, twig, and ini were not unconditionally blocked, and the filename was not normalized to strip directory traversal sequences or path separators.

Attack Vector

The vulnerability is exploitable over the network without authentication or user interaction. An attacker submits a multipart POST request to a Grav page containing a form configured with a permissive accept rule and the default destination: self@. The filename parameter targets the page's .md file, replacing its contents with attacker-controlled frontmatter and body.

php
        $grav->fireEvent('onFormUploadSettings', new Event(['settings' => &$settings, 'post' => $post]));

        $upload = json_decode(json_encode($this->normalizeFiles($_FILES['data'], $settings->name)), true);
-        $filename = $post['filename'] ?? $upload['file']['name'];
+        // Strip any path component from the POST-supplied filename. The admin
+        // controllers already do this; the public form path historically did
+        // not, which let an attacker collide the upload with files outside
+        // the intended destination.
+        $filename = Utils::basename((string) ($post['filename'] ?? $upload['file']['name']));
        $field = $upload['field'];

        // Handle errors and breaks without proceeding further

Source: getgrav/grav-plugin-form commit 48bacc4. The patch wraps the filename in Utils::basename() to strip directory components and adds an unconditional block on page-content extensions.

Detection Methods for CVE-2026-42845

Indicators of Compromise

  • POST requests to Grav form endpoints containing a filename field with path separators (/, \) or page-content extensions (.md, .yaml, .yml, .json, .twig, .ini).
  • Unexpected modifications to .md files under the Grav user/pages/ directory, particularly outside admin sessions.
  • New or altered process: save blocks in page frontmatter referencing administrative file paths.
  • Creation or modification of user/accounts/*.yaml files following form upload activity.

Detection Strategies

  • Inspect web server access logs for multipart uploads where the filename value contains .., slashes, or restricted extensions.
  • Enable file integrity monitoring on the Grav user/pages/ and user/accounts/ directories to flag unauthorized writes.
  • Audit Grav page frontmatter for unexpected form: and process: directives introduced after the deployment window.

Monitoring Recommendations

  • Log all form submissions handled by the plugin and retain the raw filename parameter for forensic review.
  • Alert on any modification of files matching *.md, *.yaml, or *.twig under content directories outside of CI/CD or admin workflows.
  • Track new super-admin accounts or password hash changes in Grav's accounts/ store.

How to Mitigate CVE-2026-42845

Immediate Actions Required

  • Upgrade the Grav form plugin to version 9.1.0 or later on all instances.
  • Audit existing forms for permissive accept rules and the use of destination: self@.
  • Review user/pages/ and user/accounts/ for recent unauthorized modifications.
  • Rotate Grav admin credentials if signs of page-content overwrite are present.

Patch Information

The fix is delivered in Grav form plugin 9.1.0. Commit 48bacc4187e1cff815000e526d5ca2878484867f calls Utils::basename() on the POST-supplied filename and hard-blocks page-content extensions (md, yaml, yml, json, twig, ini) regardless of the configurable dangerous-extensions list. Refer to GHSA-w4rc-p66m-x6qq for the advisory details.

Workarounds

  • Replace destination: self@ with a dedicated upload directory outside user/pages/ until the plugin can be updated.
  • Restrict the form accept policy to specific MIME types and extensions required by the use case.
  • Place upload-handling forms behind authentication or a web application firewall (WAF) rule that rejects filename values containing path separators or page-content extensions.
bash
# Update Grav form plugin via the bin/gpm utility
cd /path/to/grav
bin/gpm update form
bin/gpm version form  # verify 9.1.0 or later

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeAuth Bypass

  • Vendor/TechGrav

  • SeverityHIGH

  • CVSS Score7.7

  • EPSS Probability0.06%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N/E:P/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
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityNone
  • CWE References
  • CWE-73
  • Technical References
  • GitHub Commit Update

  • GitHub Security Advisory GHSA-w4rc-p66m-x6qq
  • Related CVEs
  • CVE-2026-42613: Grav Login Plugin Auth Bypass Vulnerability

  • CVE-2026-42844: Grav CMS Privilege Escalation Vulnerability

  • CVE-2026-42842: Grav CMS Form Plugin XSS Vulnerability

  • CVE-2026-44737: Grav Admin Plugin XSS Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English