GitPython versions before 3.1.54 contain an arbitrary file overwrite vulnerability in the Diffable.diff method that fails to validate git options passed through kwargs. Attackers can supply the --output argument via the other parameter or output kwarg to write patch content to attacker-chosen file paths at process privilege level.
https://www.vulncheck.com/advisories/gitpython-before-arbitrary-file-overwrite-via-diff
https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-fjr4-x663-mwxc
Published: 2026-08-13
Updated: 2026-08-13
Base Score: 8.5
Vector: CVSS2#AV:N/AC:L/Au:S/C:N/I:C/A:C
Severity: High
Base Score: 8.1
Vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H
Severity: High
Base Score: 7.2
Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:H/VA:H/SC:N/SI:N/SA:N
Severity: High