ZeroHour

CVE-2026-73622

PoC mass

Secret Exfiltration via Environment Variable Expansion in GitPython URL Handling

CVSS 4.0
8.7 high
EPSS
<1%p29
Published
()
Modified
AI analysis

GitPython before 3.1.55 does not disable environment variable expansion when handling URLs passed to Remote.create() and Submodule.add(), so an attacker-supplied URL containing variable references is expanded before being written. The expanded values are stored in .git/config and .gitmodules and are then transmitted to attacker-controlled hosts when the repository performs fetch or pull operations. An attacker who can influence a remote or submodule URL can therefore read secrets held in environment variables (an information-disclosure impact, consistent with the CVSS 4.0 score of 8.7 with confidentiality impact only). Any application, CI pipeline, or tooling that uses GitPython to create remotes or add submodules with URLs not fully trusted is affected. Exploitation has not been reported in the wild; a public proof-of-concept advisory (GHSA-94p4-4cq8-9g67) exists and EPSS assigns a low 0.4% probability of exploitation in the next 30 days.

What to do: Upgrade GitPython to 3.1.55 or later. Until patched, avoid creating remotes or adding submodules with URLs derived from untrusted input, or validate/sanitize URLs for variable-reference characters before use. Audit .git/config and .gitmodules for unexpectedly expanded values, and rotate any secrets that may have been transmitted to untrusted hosts during fetch or pull operations.

Affected
gitpython project gitpythonall versions before 3.1.55 (fixed in 3.1.55)
Estimated exposure
massmillions of Python environments/installs (tens of millions of monthly PyPI downloads); only deployments passing attacker-influenced URLs to… — GitPython is one of the most-downloaded packages on PyPI (tens of millions of downloads per month) and is a common direct or transitive dependency in developer tooling, automation, and CI images, implying an installed base plausibly…

Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.

Description

GitPython before 3.1.55 fails to disable environment variable expansion in Remote.create() and Submodule.add() URL handling, allowing attackers to exfiltrate secrets by supplying URLs containing variable references. Attackers can craft URLs with environment variable tokens that are expanded into .git/config and .gitmodules, then transmitted to attacker-controlled hosts during fetch or pull operations.

Vendors
gitpython project
Products
gitpython
Weakness
CWE-200
Vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

In the news

No ingested article mentions this CVE yet.