---
schema_version: '1.0'
id: security-20260903-44f1e8
title: CVE-2026-76221 — gitpython
url: https://osv.dev/vulnerability/PYSEC-2026-3783
url_hash: 44f1e886e035de09c03ee1c1d3d7f7a4f51a7ba406e4014506735accf7cbb190
canonical_url: https://osv.dev/vulnerability/PYSEC-2026-3783
source: osv:pypa
category: security/library
category_raw: cve/library
region: null
tags:
- cve
- CVE-2026-76221
- PYSEC-2026-3783
- severity:CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/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
- gitpython
- PyPI
lang: en
published_at: '2026-08-19T14:17:48Z'
fetched_at: '2026-09-03T11:30:56.124493Z'
updated_at: '2026-09-03T14:35:27Z'
status: published
content_hash: ef7517b4dab67cdd30102bb439ee6f4cde49c3a006f76f72c4a0d237468f3856
content_changed_at: null
license_note: full
summary: GitPython before 3.1.58 contains a config-name injection vulnerability in
  the option-name validator that allows attackers to forge arbitrary git-config directives
  by injecting equals signs, hash symbols, and whitespace into option names. Attackers
  can inject malicious option name
summary_source: rss
summary_en: GitPython before 3.1.58 contains a config-name injection vulnerability
  in the option-name validator that allows attackers to forge arbitrary git-config
  directives by injecting equals signs, hash symbols, and whitespace into option names.
  Attackers can inject malicious option name
summary_omitted_reason: null
redistribution: true
keywords_en:
- cve
- CVE-2026-28684
- CVE-2026-76221
- gitpython
- library vulnerability
- PyPI
- PYSEC-2026-3783
- software security
entities_en:
- name: CVE-2026-28684
  type: event
topics_en:
- library vulnerability
- software security
numeric_facts: []
entities:
- name: CVE-2026-28684
  type: event
key_facts: []
related: []
related_auto: []
computed_at: '2026-09-03T14:34:12Z'
---

# CVE-2026-76221 — gitpython

## TL;DR
GitPython before 3.1.58 contains a config-name injection vulnerability in the option-name validator that allows attackers to forge arbitrary git-config directives by injecting equals signs, hash symbols, and whitespace into option names. Attackers can inject malicious option name

## Key Points
- cve / CVE-2026-76221 / PYSEC-2026-3783 / severity:CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/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 / gitpython / PyPI

## Details
**Severity:** CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/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
**Advisory:** PYSEC-2026-3783 (CVE-2026-76221)

**Details:**
GitPython before 3.1.58 contains a config-name injection vulnerability in the option-name validator that allows attackers to forge arbitrary git-config directives by injecting equals signs, hash symbols, and whitespace into option names. Attackers can inject malicious option names like 'sshCommand = touch /tmp/RCE #' to execute arbitrary commands via core.sshCommand or core.hooksPath on the next git operation.

**References:**
- https://www.vulncheck.com/advisories/gitpython-before-config-injection-via-option-name
- https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-jm78-9fvv-mhgr

_Data: OSV.dev (upstream: pypa) — https://osv.dev/vulnerability/PYSEC-2026-3783_

## Source
元記事: [CVE-2026-76221 — gitpython](https://osv.dev/vulnerability/PYSEC-2026-3783) — published 2026-08-19T14:17:48Z
