Description
Grav before 2.0.16 contains a path traversal vulnerability in MediaUploadTrait::deleteFile() that allows authenticated users with media management permissions to delete arbitrary files by supplying filenames with directory traversal sequences. The method validates only the basename portion of the filename while preserving unvalidated directory paths containing ../ sequences that are passed to unlink(), enabling deletion of files outside the intended media storage directory.
Published: 2026-08-25
Score: 7.1 High
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Grav before version 2.0.16 contains a path traversal flaw in the MediaUploadTrait::deleteFile() method that lets authenticated users who have media‑management rights delete any file on the server. The code checks only the basename of the supplied filename, ignoring embedded "../" sequences; when passed to unlink() these sequences enable removal of files outside the designated media directory. The impact is the loss of confidentiality or integrity of arbitrary files, which could undermine site stability or allow an attacker to delete logs or configuration files.

Affected Systems

The affected vendor is getgrav and the product is Grav CMS. All installations of Grav running a version earlier than 2.0.16 are vulnerable, regardless of operating system or deployment environment.

Risk and Exploitability

The CVSS score of 7.1 indicates a high severity risk. EPSS is not available, so the current probability of exploitation is unknown, but the vulnerability is not yet listed in CISA KEV. The attack requires web authentication with media‑management permissions; therefore the attacker must first access the CMS and then provide a crafted filename containing directory traversal characters to trigger the delete.

Generated by OpenCVE AI on August 25, 2026 at 03:24 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Apply the Grav update to at least version 2.0.16, which removes the path‑traversal flaw.
  • Limit the set of users granted media‑management permissions so only trusted personnel can delete files.
  • Deploy a secondary input‑validation layer that strips path traversal characters before passing filenames to the deleteFile method.

Generated by OpenCVE AI on August 25, 2026 at 03:24 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Tue, 25 Aug 2026 02:00:00 +0000

Type Values Removed Values Added
Description Grav before 2.0.16 contains a path traversal vulnerability in MediaUploadTrait::deleteFile() that allows authenticated users with media management permissions to delete arbitrary files by supplying filenames with directory traversal sequences. The method validates only the basename portion of the filename while preserving unvalidated directory paths containing ../ sequences that are passed to unlink(), enabling deletion of files outside the intended media storage directory.
Title Grav before 2.0.16 Path Traversal via MediaUploadTrait deleteFile
First Time appeared Getgrav
Getgrav grav
Weaknesses CWE-22
CPEs cpe:2.3:a:getgrav:grav:*:*:*:*:*:*:*:*
Vendors & Products Getgrav
Getgrav grav
References
Metrics cvssV3_1

{'score': 8.1, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H'}

cvssV4_0

{'score': 7.1, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-08-25T01:30:11.868Z

Reserved: 2026-08-10T13:02:20.828Z

Link: CVE-2026-72695

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-08-25T02:16:45.097

Modified: 2026-08-25T02:16:45.097

Link: CVE-2026-72695

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-25T03:30:05Z

Weaknesses
  • CWE-22

    Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')