Medium severity · published Sep 26, 2026
CVE-2026-100689
GitPython before 3.1.62 Path Traversal via gitmodules path
5.9
CVSS
0.4%
EPSS
No
On KEV
Description
GitPython before 3.1.62 does not validate the `path` field read from an untrusted .gitmodules file when updating submodules. While a prior fix (GHSA-hmq2-w58f-27jc) added Submodule._validated_name() to constrain the `name` field, and GitPython's own containment guard Submodule._to_relative_path() is applied in add() and move(), Submodule.update() derives the absolute checkout location from the raw `path` value without that guard. A .gitmodules entry containing directory traversal components (e.g., path = ../../../tmp/escaped) can therefore cause directories to be created via os.makedirs() outside the repository working tree, populated from the submodule URL on the clone path, and removed via shutil.rmtree() when force_remove is used. Exploitation requires an application flow that updates submodules at a non-HEAD commit (such as a historical-commit API); the common clone-then-update flow re-derives the path from a canonical tree lookup and is not affected. The issue is fixed in GitPython 3.1.62.
CVSS vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:N/I:H/A:L
Attack vector
Network
Complexity
High
Privileges
None
User interaction
Required
Confidentiality
None
Integrity
High
Availability
Low
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)0.4% · higher than 34% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
GI
GitPython · gitpython-developers
before 3.1.62 · source: vendor
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2026-100689
CVE.org
https://www.cve.org/CVERecord?id=CVE-2026-100689
vendor-advisory
https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-59cr-6r3x-644w
third-party-advisory
https://www.vulncheck.com/advisories/gitpython-before-3.1.62-path-traversal-via-gitmodules-path
More from GitPython
9.8
CVE-2026-78676
GitPython before 3.1.59 Remote Code Execution via Config Injection
9.8
CVE-2026-67324
GitPython 3.1.50 Authentication Bypass via Joined Short Options
9.8
CVE-2026-42284
GitPython: Unsafe option check validates multi_options before shlex.split transforms it
8.8
CVE-2026-87817
GitPython before 3.1.60 Remote Code Execution via Git Directory Impersonation
8.8
CVE-2026-76221
GitPython before 3.1.58 Config Injection via option-name
