Skip to main content

Grav Database Plugin CVE-2026-58493

| EUVDEUVD-2026-42948 MEDIUM
Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection') (CWE-74)
2026-07-10 GitHub_M
5.1
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Compromise or obtain Grav admin credentials
  2. Delivery
    Authenticate to Grav admin panel
  3. Exploit
    Navigate to Database plugin configuration
  4. Install
    Inject malicious DSN attribute or path traversal into YAML config field
  5. C2
    Plugin constructs poisoned PDO DSN string
  6. Execute
    PDO connects to unintended database or filesystem path
  7. Impact
    Access or influence unintended data

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Input neutralization, injection prevention
Exploitation Conditions

Exploitation requires administrator-level access to the Grav CMS plugin configuration interface - specifically, the ability to write to the database plugin's YAML configuration fields (host, dbname, charset, server, database, directory, filename). This is a PR:H (high-privilege) condition. Exploitation is further limited to environments where the grav-plugin-database plugin is installed and active; sites running Grav CMS without this optional plugin are not affected. The attack is not exploitable by unauthenticated users or lower-privilege Grav roles. What limits exploitation in practice: (1) admin credentials must already be compromised or the attack must be an insider threat; (2) the DSN injection impact is constrained to database connection parameters, not arbitrary OS command execution; (3) path traversal impact depends on the PDO driver in use (SQLite-based drivers are more susceptible than MySQL/PostgreSQL which do not use filesystem paths in DSN fields).

Impact

The CVSS 4.0 base score of 5.1 with vector AV:N/AC:L/AT:N/PR:H/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N accurately reflects the constrained real-world risk: exploitation requires PR:H (high-privilege, administrator-level) access to the Grav plugin configuration interface, substantially limiting the attack surface to insider threats or compromised admin accounts. The network attack vector (AV:N) acknowledges that the Grav admin panel is typically web-accessible, but the PR:H requirement means this is not a remotely unauthenticated issue. The confidentiality and integrity impacts are both rated Low, consistent with partial database misdirection or limited path traversal rather than full system compromise. No KEV listing and no public POC have been identified, and the EPSS signal is not provided - this reduces urgency significantly. The vulnerability is best characterized as a privilege-boundary control flaw affecting trust assumptions within the admin tier, not a lateral escalation or remote exploitation path. For organizations where admin credentials are tightly controlled, this poses minimal incremental risk beyond already-trusted administrator access.

Exploit ScenarioDerived

An attacker who has obtained Grav CMS administrator credentials - through credential stuffing, phishing, or a compromised account - navigates to the Database plugin configuration panel and modifies the host or directory YAML field to include injected DSN attributes such as localhost;unix_socket=/var/run/attacker/malicious.sock or a path traversal value like ../../sensitive_dir. When the plugin subsequently invokes Database::__call, the malformed DSN is passed to PDO, redirecting the database connection to an unintended socket or filesystem location, potentially exposing data from an alternate database or traversing to restricted file paths. No public POC has been identified at time of analysis.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 10, 2026

DSN string injection in grav-plugin-database prior to version 1.2.0 allows an administrator with Grav CMS plugin configuration access to manipulate PDO database connection strings by injecting unsanitized YAML field values. The vulnerable Database::__call method concatenates fields such as host, dbname, charset, server, database, directory, and filename directly into DSN strings without validation, enabling DSN attribute injection or path traversal to redirect database connections to unintended targets. No public exploit code or active exploitation has been identified at time of analysis; the fix is available in version 1.2.0.

RemediationAI

Upgrade grav-plugin-database to version 1.2.0, which addresses the issue per the upstream commit at https://github.com/getgrav/grav-plugin-database/commit/f6d058785c9e23df7efc5ea7556f8746fef286df and the release tag at https://github.com/getgrav/grav-plugin-database/releases/tag/1.2.0. If upgrading immediately is not feasible, restrict access to the Grav admin panel to trusted networks or authenticated VPN sessions to prevent unauthorized administrators from reaching the plugin configuration interface - note this does not eliminate the risk from legitimate but compromised admin accounts. As an additional control, audit existing YAML configuration values in the database plugin settings for unexpected semicolons, path traversal sequences (e.g., ../), or unknown DSN attributes, and normalize them to known-good values. There are no additional vendor-published workarounds beyond patching.

Affected VersionsENISA

grav < 1.2.0

Affected Packages

euvd grav fix: 1.2.0

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

The vulnerability resides in the Database::__call method of grav-plugin-database, a plugin extending Grav CMS (CPE: cpe:2.3:a:getgrav:grav:*:*:*:*:*:*:*:*). PHP's PDO layer constructs database connections via DSN strings such as mysql:host=...;dbname=...;charset=..., where each semicolon-delimited key-value pair can override or extend connection parameters. Because the plugin reads connection parameters directly from administrator-controlled YAML configuration fields without sanitization, CWE-74 (Injection) is the root cause - specifically, an attacker controlling these YAML values can inject additional DSN segments (e.g., appending ;unix_socket=/tmp/attacker.sock) or supply path traversal sequences in filesystem-based DSN fields like directory and filename used by SQLite drivers. The result is that the PDO constructor receives an attacker-influenced DSN rather than the intended one.

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

Vendor (GitHub_M) PRIMARY 5.1 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
vuln.today AI 3.8 LOW

Admin-only web panel access sets PR:H and AV:N; DSN injection yields partial data and connection integrity impact only.

3.1 AV:N/AC:L/PR:H/UI:N/S:U/C:L/I:L/A:N
4.0 AV:N/AC:L/AT:N/PR:H/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
High
User Interaction
None
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
Patch available
Jul 10, 2026 - 18:01 EUVD

DescriptionCVE.org

grav-plugin-database is the database plugin for Grav CMS. Prior to 1.2.0, Database::__call builds PDO DSN strings by directly concatenating user-configurable YAML values from fields such as host, dbname, charset, server, database, directory, and filename without sanitization or validation, allowing an administrator with plugin configuration access to inject DSN attributes or path traversal values. This issue is fixed in version 1.2.0.

Threat Intelligence Overview

EPSS Score
0.3%
Top 79% exploitable
Prevalence
Low
optional plugin for a niche flat-file CMS with limited enterprise adoption
Data Quality
6 sources
Confidence: High

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.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

26
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.

More in Grav

View all
CVE-2025-66294 HIGH POC
8.7 Dec 01

Server-side template injection (SSTI) in Grav (getgrav/grav) prior to 1.8.0-beta.27 allows an authenticated attacker hol

CVE-2025-66301 HIGH POC
8.6 Dec 01

Broken access control in Grav CMS (CWE-285) before 1.8.0-beta.27 lets an authenticated editor-level user escalate their

CVE-2025-50286 HIGH POC
8.1 Aug 06

A Remote Code Execution (RCE) vulnerability in Grav CMS v1.7.48 allows an authenticated admin to upload a malicious plug

CVE-2024-34082 CRITICAL POC
9.9 May 15

Grav is a file-based Web platform. Rated critical severity (CVSS 9.9), this vulnerability is remotely exploitable, low a

CVE-2021-47812 CRITICAL POC
9.8 Jan 16

GravCMS 1.10.7 allows unauthenticated remote attackers to write arbitrary YAML configuration files, leading to full serv

CVE-2026-65008 CRITICAL POC
9.3 Jul 21

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

CVE-2026-75827 CRITICAL POC
9.3 Aug 18

Remote code execution in Grav CMS before 2.0.15 allows attackers holding page-edit or blueprint-config privileges to wri

CVE-2026-75837 CRITICAL POC
9.3 Aug 18

Vertical privilege escalation in Grav CMS before 2.0.14 lets a delegated administrator holding only the admin.users perm

CVE-2026-75828 CRITICAL POC
9.3 Aug 18

Stored cross-site scripting in Grav CMS before 2.0.15 lets authenticated editors smuggle JavaScript event handlers past

CVE-2025-66844 CRITICAL POC
9.1 Dec 15

Server-side request forgery (SSRF) in Grav CMS versions prior to 1.7.49.5 allows remote authenticated attackers to make

CVE-2025-66299 HIGH POC
8.8 Dec 01

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

CVE-2026-72819 HIGH POC
8.7 Aug 14

Remote code execution in Grav CMS before 2.0.13 allows authenticated low-privilege users to plant and execute arbitrary

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy