CVE-2026-42284

Name
CVE-2026-42284
Description
GitPython is a python library used to interact with Git repositories. Prior to version 3.1.47, _clone() validates multi_options as the original list, then executes shlex.split(" ".join(multi_options)). A string like "--branch main --config core.hooksPath=/x" passes validation (starts with --branch), but after split becomes ["--branch", "main", "--config", "core.hooksPath=/x"]. Git applies the config and executes attacker hooks during clone. This issue has been patched in version 3.1.47.
NVD Severity
unknown
Other trackers
Mailing lists
Exploits
Forges
GitHub (code, issues), Aports (code, issues)

References

Type URI
Patch https://github.com/gitpython-developers/GitPython/releases/tag/3.1.47
Exploit https://github.com/gitpython-developers/GitPython/security/advisories/GHSA-x2qx-6953-8485
134c704f-9b21-4f2e-91b3-4a467353bcc0 https://www.tenable.com/cve/CVE-2026-32686

Match rules

CPE URI Source package Min version Max version
cpe:2.3:a:gitpython_project:gitpython:*:*:*:*:*:python:*:* py3-gitpython >= None < 3.1.47

Vulnerable and fixed packages

Source package Branch Version Maintainer Status
py3-gitpython edge-community 3.1.49-r0 Wen Heping <wenhepingalpine@sohu.com> fixed
py3-gitpython edge-community 3.1.46-r1 Wen Heping <wenhepingalpine@sohu.com> possibly vulnerable
py3-gitpython edge-community 3.1.46-r0 Wen Heping <wenhepingalpine@sohu.com> possibly vulnerable
py3-gitpython edge-community 3.1.44-r0 None possibly vulnerable
py3-gitpython edge-community 3.1.43-r1 Bart Ribbers <bribbers@disroot.org> possibly vulnerable
py3-gitpython edge-community 3.1.37-r0 Bart Ribbers <bribbers@disroot.org> possibly vulnerable
py3-gitpython edge-community 3.1.35-r0 Bart Ribbers <bribbers@disroot.org> possibly vulnerable
py3-gitpython 3.24-community 3.1.49-r0 Wen Heping <wenhepingalpine@sohu.com> fixed
py3-gitpython 3.23-community 3.1.49-r0 Wen Heping <wenhepingalpine@sohu.com> fixed
py3-gitpython 3.23-community 3.1.44-r0 None possibly vulnerable