CVE 7.8 HIGH

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

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

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.

Basic Information

ID CVE-2026-44244
Source GitHub_M
Published May 7, 2026 at 18:22

Affected Product

Vendor gitpython-developers
Product GitPython
Version < 3.1.49
Affected Versions gitpython-developers GitPython < 3.1.49

CWE Classification

References

💭 Join the Security Discussion

🔒 Your email address will not be published. Required fields are marked *

⚠️ Please be respectful and constructive in your comments. Security discussions should remain professional.