Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. GitPython
  4. ›
  5. CVE-2026-78676

CVE-2026-78676: GitPython: Dormant multi-line git-config values are corrupted into live injected directives (e.g. core.hooksPath) on any unrelated GitConfigParser write, enabling RCE

September 8, 2026

  • CWE: CWE-88 (Argument Injection) / CWE-94 (Code Injection) — via a read-then-corrupt-on-rewrite config round trip, not a direct setter argument
  • Affected component: git/config.py — GitConfigParser._read() (multi-line value decoding, lines 444-541, esp. string_decode() at line 460 and its call sites at 519/541) and GitConfigParser._write()/write_section() (serialization, lines ~694-712, esp. line 708)
  • Affected version: GitPython at HEAD (9729ed3b948f2bde09f1f188c5311e172212b67e, 2026-08-05, VERSION 3.1.58)

References

  • github.com/advisories/GHSA-284h-m62q-gf8w
  • github.com/gitpython-developers/GitPython/security/advisories/GHSA-284h-m62q-gf8w
  • github.com/pypa/advisory-database/tree/main/vulns/gitpython/PYSEC-2026-3786.yaml
  • nvd.nist.gov/vuln/detail/CVE-2026-78676
  • www.vulncheck.com/advisories/gitpython-before-remote-code-execution-via-config-injection

Code Behaviors & Features

Detect and mitigate CVE-2026-78676 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 3.1.59

Fixed versions

  • 3.1.59

Solution

Upgrade to version 3.1.59 or above.

Impact 9.8 CRITICAL

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Learn more about CVSS

Weakness

  • CWE-88: Improper Neutralization of Argument Delimiters in a Command ('Argument Injection')
  • CWE-94: Improper Control of Generation of Code ('Code Injection')

Source file

pypi/GitPython/CVE-2026-78676.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 09 Sep 2026 12:22:13 +0000.