# CVE-2026-67326: GitPython before 3.1.50 Newline Injection via config_writer section

- Severity: High 7.3 (CVSS:4.0, scored by VulnCheck) `CVSS:4.0/AV:L/AC:H/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.43%, higher than 38% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-05-08T23:19:02.000Z
- Modified: 2026-10-23T23:10:00.157Z
- Also known as: GHSA-mv93-w799-cj2w, PYSEC-2026-3980
- Weaknesses: CWE-20
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact total
- Assigned by: VulnCheck

## Description

GitPython before 3.1.50 fails to validate newline characters in the section parameter of config_writer(), allowing attackers to inject arbitrary section headers into .git/config. Attackers can inject newlines to create a forged [core] section with hooksPath pointing to attacker-controlled directories, achieving remote code execution when git hooks are triggered.

(As written by CVE List.)

## Affected

- gitpython-developers GitPython: before 3.1.50 (not affected: 3.1.50)
- gitpython (PyPI): before 3.1.50
- gitpython_project gitpython: before 3.1.50

## Every score

- VulnCheck: CVSS:4.0 7.3 High `CVSS:4.0/AV:L/AC:H/AT:P/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- VulnCheck: CVSS:3.1 7.0 High `CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H`
- GitHub: CVSS:3.1 7.0 High `CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- PyPA Advisory Database: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`

## References

- <https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-mv93-w799-cj2w> (exploit, evidence, vendor-advisory, web)
- <https://www.vulncheck.com/advisories/gitpython-before-newline-injection-via-config-writer-section> (advisory, third-party-advisory)
- <https://github.com/advisories/GHSA-rpm5-65cw-6hj4> (advisory)
- <https://github.com/gitpython-developers/GitPython> (package)

## Sources

- CVE List: [CVE-2026-67326](https://www.cve.org/CVERecord?id=CVE-2026-67326), CVE Terms of Use, modified 2026-08-14
- GitHub Advisory Database: [GHSA-mv93-w799-cj2w](https://github.com/advisories/GHSA-mv93-w799-cj2w), CC-BY-4.0, modified 2026-09-17
- NVD: [CVE-2026-67326](https://nvd.nist.gov/vuln/detail/CVE-2026-67326), Public domain, modified 2026-10-23
- PyPA Advisory Database: [PYSEC-2026-3980](https://osv.dev/vulnerability/PYSEC-2026-3980), CC-BY-4.0, modified 2026-09-17

---

Page: https://cve.day/CVE-2026-67326 · Whole record: https://cve.day/CVE-2026-67326.json · Rebuilt by cve.day 2026-11-25T22:59:30.790Z
