Vulnerability · Published Aug 19, 2026 · Assigned by VulnCheck
CVE-2026-76222GitPython before 3.1.58 Path Traversal via .gitmodules Submodule Name
High 8.2
In plain English
A high-severity path traversal in GitPython from gitpython-developers. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.4% (higher than 37% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official 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 packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine:v3.24 | py3-gitpython | 3.1.61-r0 | ALPINE-CVE-2026-76222 |
| Debian:12 | python-git | 3.1.30-1+deb12u3 | DEBIAN-CVE-2026-76222 |
| Debian:13 | python-git | 3.1.44-1+deb13u1 | DEBIAN-CVE-2026-76222 |
| Debian:14 | python-git | 3.1.61-1 | DEBIAN-CVE-2026-76222 |
| PyPI | gitpython | 3.1.58 | PYSEC-2026-3784 |
| PyPI | gitpython | 3.1.58 | GHSA-hmq2-w58f-27jc |
| Ubuntu:26.10 | python-git | no fix listed | UBUNTU-CVE-2026-76222 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| gitpython-developers | GitPython | 0 – before 3.1.58 |
Weakness: CWE-22 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:N/I:H/A:L
References
- GitHub Security Advisory (GHSA-hmq2-w58f-27jc) vendor-advisory
- VulnCheck Advisory: GitPython before 3.1.58 Path Traversal via .gitmodules Submodule Name third-party-advisory