What’s Vulnerable › Vulnerabilities
CVE-2026-78677: GitPython before 3.1.59 Path Traversal via separate-git-dir
- Severity: high (CVSS 7.5 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.7% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2026-08-25 · updated 2026-10-12
- Weakness: CWE-22
Description
GitPython before 3.1.59 omits --separate-git-dir from unsafe_git_clone_options, allowing attackers to create arbitrary git directories outside the intended clone destination. Attackers can pass a separate_git_dir parameter to Repo.clone_from() or Repo.clone() to redirect repository metadata to an attacker-controlled filesystem path, enabling arbitrary directory creation and potential hook execution.
Affected products
- gitpython-developers GitPython: before 3.1.59 — fixed in 3.1.59
How to fix
Upgrade to a fixed version: gitpython-developers GitPython 3.1.59. Check the vendor advisory for mitigations.
References
- https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-8mcc-hrx5-hvxc
- https://www.vulncheck.com/advisories/gitpython-before-path-traversal-via-separate-git-dir
- https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-8mcc-hrx5-hvxc
Get alerted when CVE-2026-78677 or the next vulnerability affects your stack