Input validation error in GitPython - CVE-2026-44244

 

Input validation error in GitPython - CVE-2026-44244

Published: May 11, 2026


Vulnerability identifier: #VU131002
CSH Severity: Low
CVSS v4: 8.5 [CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N]
CVE-ID: CVE-2026-44244
CWE-ID: CWE-20
Exploitation vector: Local access
Exploit availability: No public exploit available

Vulnerability details

The vulnerability allows a local user to execute arbitrary code.

The vulnerability exists due to improper input validation in GitConfigParser.set_value() when writing user-supplied configuration values to .git/config. A local user can inject newline characters to create a malicious core.hooksPath setting and execute arbitrary code.

Any Git operation that invokes hooks, such as commit, merge, or checkout, may trigger execution from the attacker-controlled path. In shared repositories, the injected configuration can persist and affect subsequent Git operations by other users.


Affected software

GitPython
Ubuntu
openEuler
python-git (Ubuntu package)
python-GitPython
python-GitPython-help
python3-GitPython

How to mitigate CVE-2026-44244

Install security update from vendor's website.

GitPython - update to 3.1.49
python-git (Ubuntu package) - addressed in versions 0.3.2~RC1-3ubuntu0.1~esm3, 1.0.1+git137-gc8b8379-2.1ubuntu0.1~esm4, 2.1.8-1ubuntu0.1~esm4, 3.0.7-1ubuntu0.1~esm4, 3.1.24-1ubuntu0.1~esm3, 3.1.37-3ubuntu0.1~esm2, 3.1.46-1ubuntu0.1~esm1
python-GitPython - update to 3.1.49-1
python-GitPython-help - update to 3.1.49-1
python3-GitPython - update to 3.1.49-1

External References

Related Security Bulletins