Skip to main content
VulnerabilityPublished Updated

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

Affects legitSource GCVE Database

0
Authoritative record:CVE-2026-44244· High 7.8

Not known to be exploited · CVSS 7.8 High : upgrade to 1.2.0.post0_9 soon.

Data as of 26 Oct 2026, 19:12 UTC

CVSS 3.1 base score
7.8High
How severe the flaw is on the 0–10 CVSS scale.
Patch
Available – fixed in 1.2.0.post0_9
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Exploitation evidence

  1. Disclosed: evidence found.

    CVE published 7 May 2026

  2. Detectable: no evidence on record.

    No public nuclei template indexed

  3. Weaponised: no evidence on record.

    No public exploit code indexed in Metasploit or Exploit-DB

  4. Exploited in the wild: no evidence on record.

    Not in CISA KEV and no source reports exploitation

  5. Observed by OffSeq Mirage: no evidence on record.

    No attack traffic recorded by OffSeq Mirage sensors

A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.

What to do

Upgrade legit to 1.2.0.post0_9.

Affected software

ProductAffectedFixed in
Homebrewlegitpkg:brew/legitOther threatsAffected
  • >=0.1.0 <1.2.0.post0_9
Fixed in
  • 1.2.0.post0_9

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

A fix is available in GitPython version 1.2.0.post0_9. Users should upgrade to this version or later. The recommended remediation is to have set_value() reject values containing carriage return, line feed, or null characters rather than silently passing them through. This prevents injection of malicious configuration sections. Applications using GitPython should audit calls to config_writer().set_value() to ensure untrusted input is sanitized or rejected.

Description

GitPython versions prior to 1.2.0.post0_9 contain a vulnerability in config_writer().set_value() where newline characters in values are not properly validated. This allows injection of a malicious core.hooksPath configuration, enabling remote code execution via Git hooks. The flaw arises because GitPython converts embedded newlines into indented continuation lines, which Git still interprets as valid section headers, activating attacker-controlled hooks. This can lead to persistent repository config poisoning, especially in multi-user or hosted environments where untrusted input is passed to set_value().

References

Community reviews

Loading reviews…