Vulnerability · Published May 7, 2026 · Assigned by GitHub_M

CVE-2026-44244GitPython: Newline injection in config_writer().set_value() enables RCE via core.hooksPath

High 7.8

In plain English

A high-severity code injection in GitPython from gitpython-developers. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 15% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)7.8High
Exploit odds (30 days)0.2%top 85.2% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack toolingNoneno public tooling known

Official description

GitPython is a python library used to interact with Git repositories. Prior to version 3.1.49, GitConfigParser.set_value() passes values to Python's configparser without validating for newlines. GitPython's own _write() converts embedded newlines into indented continuation lines (e.g. \n becomes \n\t), but Git still accepts an indented [core] stanza as a section header — so the injected core.hooksPath becomes effective configuration. Any Git operation that invokes hooks (commit, merge, checkout) will then execute scripts from the attacker-controlled path. This issue has been patched in version 3.1.49.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12python-git3.1.30-1+deb12u3DEBIAN-CVE-2026-44244
Debian:13python-git3.1.44-1+deb13u1DEBIAN-CVE-2026-44244
Debian:14python-git3.1.50-1DEBIAN-CVE-2026-44244
PyPIgitpython3.1.49PYSEC-2026-2163
PyPIgitpython3.1.49GHSA-v87r-6q3f-2j67
Ubuntu:25.10python-gitno fix listedUBUNTU-CVE-2026-44244
Ubuntu:26.10python-gitno fix listedUBUNTU-CVE-2026-44244

Affected products (as reported)

VendorProductVersions
gitpython-developers GitPython < 3.1.49

Weakness: CWE-94 · Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

References