Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-109326 Overview
CVE-2026-109326 is an information disclosure vulnerability affecting Grav flat-file content management system (CMS) versions prior to 2.1.7. The bundled web server configurations for nginx, lighttpd, Internet Information Services (IIS), and Caddy 2 block access to .git directories only at the document root. Unauthenticated attackers can request nested repositories such as user/.git to retrieve Git configuration files, references, and object data. This exposure allows reconstruction of unpublished commit history and recovery of committed secrets.
Critical Impact
Remote, unauthenticated attackers can retrieve Git repository contents from Grav installations, leading to exposure of source code, credentials, and configuration data committed to nested repositories [CWE-527].
Affected Products
- Grav CMS versions before 2.1.7
- Grav installations using bundled nginx configuration
- Grav installations using bundled lighttpd, IIS, or Caddy 2 configurations
Discovery Timeline
- 2026-10-12 - CVE-2026-109326 published to the National Vulnerability Database (NVD)
- 2026-10-12 - Last updated in NVD database
Technical Details for CVE-2026-109326
Vulnerability Analysis
Grav ships web server configuration templates that restrict access to Git metadata directories. The restriction rules match .git only at the document root path, not at arbitrary nested locations within the webroot. Grav's directory structure contains subdirectories such as user/, which administrators may initialize as independent Git repositories to version-control themes, plugins, or site content.
When a nested .git directory exists at a path like /user/.git/, the bundled web server rules do not match the request. The web server treats the directory and its contents as static files and serves them to any requester. Attackers can retrieve HEAD, config, index, packed-refs, and loose objects under objects/.
With these files, an attacker reconstructs the repository offline using standard Git tooling. This reveals unpublished branches, deleted content, and any secrets committed to history, including API keys, database credentials, and private keys.
Root Cause
The root cause is incomplete path matching in bundled web server configurations. The nginx, lighttpd, IIS, and Caddy 2 templates anchor the .git block rule to the document root rather than applying it recursively to any .git directory under the webroot. This maps to CWE-527: Exposure of Version-Control Repository to an Unauthorized Control Sphere.
Attack Vector
The attack requires no authentication, no user interaction, and no elevated privileges. An attacker sends ordinary HTTP GET requests to predictable paths such as /user/.git/HEAD, /user/.git/config, and /user/.git/objects/pack/. Successful responses confirm the exposure, after which the attacker enumerates refs and downloads objects to reconstruct the repository locally.
Access to committed secrets can enable follow-on attacks against databases, cloud providers, or administrative interfaces referenced in the repository.
Detection Methods for CVE-2026-109326
Indicators of Compromise
- HTTP GET requests to paths containing /.git/ beneath the document root, particularly /user/.git/HEAD, /user/.git/config, or /user/.git/index
- Sequential requests enumerating /user/.git/refs/heads/ and /user/.git/objects/ paths
- HTTP 200 responses from URIs containing .git segments where 403 or 404 is expected
- User-Agent strings associated with tools such as git-dumper or custom repository scrapers
Detection Strategies
- Review web server access logs for any 2xx responses to request paths containing .git/ beyond the document root
- Deploy web application firewall (WAF) rules that block or alert on URI patterns matching /\.git/ anywhere in the path
- Correlate repeated requests from a single source IP across multiple Git metadata endpoints as repository enumeration activity
Monitoring Recommendations
- Ingest nginx, lighttpd, IIS, and Caddy access logs into a centralized logging platform and alert on .git path access
- Baseline normal request patterns for Grav deployments and flag anomalous bursts of requests to /user/, /themes/, or /plugins/ paths
- Monitor outbound alerts from credential-leak scanners for secrets observed in exposed Grav Git histories
How to Mitigate CVE-2026-109326
Immediate Actions Required
- Upgrade Grav to version 2.1.7 or later to apply the corrected web server configuration templates
- Audit webroot directories for nested .git folders and remove or relocate them outside the document root where feasible
- Rotate any credentials, API keys, or tokens that were committed to repositories exposed through the webroot
- Review web server access logs for prior successful requests to .git paths and treat confirmed access as a disclosure incident
Patch Information
Grav 2.1.7 corrects the bundled nginx, lighttpd, IIS, and Caddy 2 configurations to block .git directories at any depth beneath the document root. Refer to the GitHub Security Advisory GHSA-5vx9-x8f2-f55w and the VulnCheck Advisory for Grav for upstream fix details.
Workarounds
- Update web server configurations to deny access to any URI path containing /.git/ or /.git$, applied recursively rather than at the document root only
- Remove .git directories from the webroot and perform Git operations from a mirror outside the public document root
- Place a reverse proxy or WAF in front of Grav to reject requests containing .git path segments until the upgrade is applied
# Configuration example: nginx recursive block for any nested .git directory
location ~ /\.git(/|$) {
deny all;
access_log off;
log_not_found off;
return 404;
}
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

