Security mailing lists by PureSourceCode

CVE-2026-42215

HIGH 8.8CVSS 3.1

GitPython has Command Injection via Git options bypass

GitPython is a python library used to interact with Git repositories. From version 3.1.30 to before version 3.1.47, GitPython blocks dangerous Git options such as --upload-pack and --receive-pack by default, but the equivalent Python kwargs upload_pack and receive_pack bypass that check. If an application passes attacker-controlled kwargs into Repo.clone_from(), Remote.fetch(), Remote.pull(), or Remote.push(), this leads to arbitrary command execution even when allow_unsafe_options is left at its default value of False. This issue has been patched in version 3.1.47.

Published
7 May 2026
Last modified
11 Nov 2026
Assigned by
security-advisories@github.com
NVD status
Analyzed
Weakness
CWE-78
Also known as
GHSA-rpm5-65cw-6hj4PYSEC-2026-2160
Sources
NVDJSONOSV GHSA-rpm5-65cw-6hj4JSONOSV PYSEC-2026-2160JSON

Scores

SourceScored byVersionScoreVector / decision
NVD security-advisories@github.com (Secondary) CVSS 3.1 HIGH 8.8 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
OSV GitHub CVSS 3.1 HIGH 8.8 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
OSV PyPA CVSS 3.1 HIGH 8.8 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
NVD gitpython_project gitpython
cpe:2.3:a:gitpython_project:gitpython:*:*:*:*:*:python:*:*
>= 3.1.30, < 3.1.47 3.1.47
OSV PyPI gitpython >= 3.1.30, < 3.1.47 3.1.47

References

History

  • 25 Nov 2026 21:02 UTC · NVD: first stored (published 7 May 2026)
  • 25 Nov 2026 20:12 UTC · OSV: first stored (published 7 May 2026)
  • 25 Nov 2026 20:12 UTC · OSV: first stored (published 25 Apr 2026)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.