CVE-2026-100689
Received Received - Intake

Path Traversal in GitPython Submodule Update

Vulnerability report for CVE-2026-100689, including description, CVSS score, EPSS score, affected products, exploitability, helpful resources, and attack-flow context.

Publication date: 2026-09-26

Last updated on: 2026-09-26

Assigner: VulnCheck

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 Scores

EPSS Scores

Probability:
Percentile:

Meta Information

Published
2026-09-26
Last Modified
2026-09-26
Generated
2026-09-26
AI Q&A
2026-09-26
EPSS Evaluated
N/A
NVD
EUVD

Affected Vendors & Products

Showing 2 associated CPEs
Vendor Product Version / Range
gitpython gitpython 3.1.62
gitpython_developers gitpython to 3.1.62 (exc)

Helpful Resources

Exploitability

CWE
CWE Icon
KEV
KEV Icon
CWE ID Description
CWE-22 The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory.

Attack-Flow Graph

AI Quick Actions

Instant insights powered by AI
Executive Summary

GitPython before 3.1.62 has a vulnerability where the path field in untrusted .gitmodules files is not properly validated during submodule updates. This allows directory traversal sequences like ../../../tmp/escaped to create directories outside the repository working tree. The issue occurs because Submodule.update() uses the raw path value without applying containment guards like Submodule._to_relative_path().

Detection Guidance

Check GitPython version with pip show GitPython. If version is <= 3.1.61, the system is vulnerable. Review .gitmodules files in repositories for suspicious path entries containing traversal sequences like ../../../.

Impact Analysis

An attacker could create arbitrary directories outside the intended repository scope using directory traversal in .gitmodules files. This could lead to unauthorized file system access, potential data leakage, or disruption of services if directories are created or deleted maliciously during submodule updates.

Mitigation Strategies

Upgrade GitPython to version 3.1.62 or later using pip install --upgrade GitPython. Avoid updating submodules at non-HEAD commits until patched. Review and sanitize .gitmodules files for malicious path entries.

Chat Assistant

Ask questions about this CVE
Hi! I’m here to help you understand CVE-2026-100689. Ask me anything about the vulnerability, its impact, or mitigation strategies.
0/70

EPSS Chart