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.
Published: 2026-08-13
Score: 8.7 High
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

GitPython versions older than 3.1.55 allow attackers to inject URLs that contain environment variable references during Remote.create() and Submodule.add() calls. The library incorrectly expands these variables into .git/config and .gitmodules files, which are then transmitted to external hosts when a fetch or pull operation occurs. This flaw enables a remote attacker to harvest sensitive configuration data that the application stores in environment variables, resulting in a confidentiality breach based on CWE‑200.

Affected Systems

The vulnerability affects the GitPython library maintained by the gitpython‑developers. All releases before 3.1.55 are impacted. Users embedding GitPython in applications or services that perform remote Git operations with potentially untrusted URLs are at risk.

Risk and Exploitability

The CVSS score of 8.7 indicates high severity. Because the flaw requires the attacker to supply a malicious URL that triggers a fetch or pull, the attack vector is remote and depends on an active network connection that performs a Git operation. Although the EPSS score is currently unavailable, the vulnerability is not listed in the CISA KEV catalog, suggesting that there may not yet be widespread exploitation, but the high CVSS rating warrants urgent action. An attacker could submit a crafted URL to a service that pulls from a repository, causing the service to expand environment variables and expose internal secrets to an external host.

Generated by OpenCVE AI on August 13, 2026 at 12:44 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade to GitPython version 3.1.55 or newer to disable environment variable expansion during Remote.add() and Submodule.add() operations.
  • If upgrading is not immediately possible, configure your environment to prevent unintended variable expansion in GitPython by ensuring that the environment used by the process does not contain sensitive variables that can be interpolated by Git.
  • Audit existing .git/config and .gitmodules files for unexpected variable references and review remote URLs to confirm they originate from trusted sources.

Generated by OpenCVE AI on August 13, 2026 at 12:44 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Thu, 13 Aug 2026 13:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'poc', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Thu, 13 Aug 2026 13:00:00 +0000

Type Values Removed Values Added
First Time appeared Gitpython-developers
Gitpython-developers gitpython
Vendors & Products Gitpython-developers
Gitpython-developers gitpython

Thu, 13 Aug 2026 11:45:00 +0000

Type Values Removed Values Added
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.
Title GitPython before 3.1.55 Environment Variable Exfiltration via Remote.add()
Weaknesses CWE-200
References
Metrics cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N'}

cvssV4_0

{'score': 8.7, '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'}


Subscriptions

Gitpython-developers Gitpython
cve-icon MITRE

Status: PUBLISHED

Assigner: VulnCheck

Published:

Updated: 2026-08-13T12:57:12.496Z

Reserved: 2026-08-13T11:17:25.160Z

Link: CVE-2026-73622

cve-icon Vulnrichment

Updated: 2026-08-13T12:56:58.006Z

cve-icon NVD

Status : Received

Published: 2026-08-13T12:17:27.337

Modified: 2026-08-13T13:19:21.070

Link: CVE-2026-73622

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-13T12:45:03Z

Weaknesses
  • CWE-200

    Exposure of Sensitive Information to an Unauthorized Actor