ADVISORIES

Ubuntu CVE Tracker

UBUNTU-CVE-2026-42284

Details

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.

Affected packages

EcosystemPackageAffected versions
Ubuntu:Pro:20.04:LTSpython-git
All versions before 3.0.7-1ubuntu0.1~esm4 (fixed in 3.0.7-1ubuntu0.1~esm4)
Ubuntu:Pro:22.04:LTSpython-git
All versions before 3.1.24-1ubuntu0.1~esm3 (fixed in 3.1.24-1ubuntu0.1~esm3)
Ubuntu:Pro:24.04:LTSpython-git
All versions before 3.1.37-3ubuntu0.1~esm2 (fixed in 3.1.37-3ubuntu0.1~esm2)
Ubuntu:25.10python-git
All versions, no fix listed
Ubuntu:26.10python-git
All versions, no fix listed
Ubuntu:Pro:26.04:LTSpython-git
All versions before 3.1.46-1ubuntu0.1~esm1 (fixed in 3.1.46-1ubuntu0.1~esm1)

References