What’s Vulnerable › Vulnerabilities
CVE-2026-76222: GitPython before 3.1.58 Path Traversal via .gitmodules Submodule Name
- Severity: high (CVSS 8.2 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.4% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2026-08-19 · updated 2026-09-02
- Weakness: CWE-22
Description
GitPython before 3.1.58 fails to validate submodule names from .gitmodules files, allowing attackers to create Git repositories at arbitrary filesystem paths outside the intended clone directory. Attackers can craft malicious repositories with traversal sequences in submodule names that GitPython processes during submodule initialization, creating attacker-controlled Git repositories at escaped filesystem locations.
Affected products
- gitpython-developers GitPython: before 3.1.58 — fixed in 3.1.58
How to fix
Upgrade to a fixed version: gitpython-developers GitPython 3.1.58. Check the vendor advisory for mitigations.
References
- https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-hmq2-w58f-27jc
- https://www.vulncheck.com/advisories/gitpython-before-path-traversal-via-gitmodules-submodule-name
- https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-hmq2-w58f-27jc
Get alerted when CVE-2026-76222 or the next vulnerability affects your stack