CVE-2026-67326
7.3
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
Summary
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.
Affected Software
| Vendor | Product | Version Range | Status |
|---|---|---|---|
| gitpython-developers | GitPython | 0 < 3.1.50 | affected |
| gitpython-developers | GitPython | 3.1.50 | unaffected |
Weaknesses
- CWE-20: Improper Input Validation
References
- https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-mv93-w799-cj2w
- https://www.vulncheck.com/advisories/gitpython-before-newline-injection-via-config-writer-section
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.