PyPA Advisory Database
PYSEC-2022-42992
Details
All versions of package gitpython are vulnerable to Remote Code Execution (RCE) due to improper user input validation, which makes it possible to inject a maliciously crafted remote URL into the clone command. Exploiting this vulnerability is possible because the library makes external calls to git without sufficient sanitization of input arguments.
Affected packages
| Ecosystem | Package | Affected versions |
|---|---|---|
| PyPI | gitpython | All versions before 3.1.30 (fixed in 3.1.30) |
References
- https://security.snyk.io/vuln/SNYK-PYTHON-GITPYTHON-3113858
- https://security.snyk.io/vuln/SNYK-PYTHON-GITPYTHON-3113858
- https://github.com/gitpython-developers/GitPython/blob/bec61576ae75803bc4e60d8de7a629c194313d1c/git/repo/base.py%23L1249
- https://lists.fedoraproject.org/archives/list/[email protected]/message/IKMVYKLWX62UEYKAN64RUZMOIAMZM5JN/
- https://lists.fedoraproject.org/archives/list/[email protected]/message/IKMVYKLWX62UEYKAN64RUZMOIAMZM5JN/
- https://lists.fedoraproject.org/archives/list/[email protected]/message/SJHN3QUXPJIMM6SULIR3PR34UFWRAE7X/
- https://lists.fedoraproject.org/archives/list/[email protected]/message/SJHN3QUXPJIMM6SULIR3PR34UFWRAE7X/
- https://github.com/advisories/GHSA-hcpj-qp55-gfph