Skip to content
OpenAdvisories
Medium · 5.5 CVE-2023-5752 EUVD-2023-0200GHSA-mq26-g339-26xfPYSEC-2023-228

Mercurial configuration injectable in repo revision when installing via pip

Published Oct 24, 2023 · Updated Nov 3, 2025 · Assigned by PSF

Description

When installing a package from a Mercurial VCS URL (ie "pip install
hg+...") with pip prior to v23.3, the specified Mercurial revision could
be used to inject arbitrary configuration options to the "hg clone"
call (ie "--config"). Controlling the Mercurial configuration can modify
how and which repository is installed. This vulnerability does not
affect users who aren't installing from Mercurial.

Affected products

VendorProductAffectedFixed
Pip maintainers pip — 23.3

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 python-pip 23.3+dfsg-1 —
Debian 13 python-pip 23.3+dfsg-1 —
Debian 12 python-pip No fix yet —
Debian 11 python-pip 20.3.4-4+deb11u2 DLA-4348-1
ReleasePackageFixed inAdvisory
Red Hat Ansible Automation Platform Inside 2 python-black +1 22.8.0-2.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Inside 2 python-cryptography +1 42.0.5-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Inside 2 python-jinja2 +1 3.1.4-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Inside 2 python39-black +1 22.8.0-2.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Inside 2 python39-cryptography +1 42.0.5-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Inside 2 python39-jinja2 +1 3.1.4-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Inside 2 receptor +1 1.4.8-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python-black +1 22.8.0-2.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python-cryptography +1 42.0.5-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python-idna +1 3.7-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python-jinja2 +1 3.1.4-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python-requests +1 2.32.2-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python39-black +1 22.8.0-2.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python39-cryptography +1 42.0.5-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python39-idna +1 3.7-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python39-jinja2 +1 3.1.4-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 python39-requests +1 2.32.2-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform Developer 2 receptor +1 1.4.8-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 automation-controller-venv-tower 4.5.7-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 automation-hub +2 4.9.2-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-aiohttp +1 3.9.5-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-black +1 22.8.0-2.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-cryptography +1 42.0.5-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-galaxy-ng +1 4.9.2-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-gunicorn +1 22.0.0-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-idna +1 3.7-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-jinja2 +1 3.1.4-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-pillow +1 10.3.0-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-pydantic +1 1.10.15-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-requests +1 2.32.2-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-social-auth-app-django +1 5.4.1-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python-sqlparse +1 0.5.0-1.el9ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-aiohttp +1 3.9.5-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-black +1 22.8.0-2.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-cryptography +1 42.0.5-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-gunicorn +1 22.0.0-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-idna +1 3.7-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-jinja2 +1 3.1.4-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-pillow +1 10.3.0-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-pydantic +1 1.10.15-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-requests +1 2.32.2-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-social-auth-app-django +1 5.4.1-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 python39-sqlparse +1 0.5.0-1.el8ap RHSA-2024:3781
Red Hat Ansible Automation Platform 2 receptor +1 1.4.8-1.el8ap RHSA-2024:3781
ReleasePackageFixed inAdvisory
SLES 12 SP5 python-pip 10.0.1-13.14.1 SUSE-SU-2023:4987-1
SLES 12 SP5 python36-pip 20.2.4-8.15.1 SUSE-SU-2024:0892-1
SLES 3 python-pip 22.3.1-150400.17.12.1 SUSE-SU-2023:4988-1
SLES 3 python312-pip 23.2.1-150600.3.3.1 SUSE-SU-2024:3156-1
Show 1 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES for SAP 12 SP5 python-pip 10.0.1-13.14.1 SUSE-SU-2023:4987-1
SLES for SAP 12 SP5 python36-pip 20.2.4-8.15.1 SUSE-SU-2024:0892-1
ReleasePackageFixed inAdvisory
openSUSE Leap 15.6 python312-pip 23.2.1-150600.3.3.1 SUSE-SU-2024:3156-1
openSUSE Leap 15.5 python-pip 22.3.1-150400.17.12.1 SUSE-SU-2023:4988-1
openSUSE Leap 15.4 python-pip 22.3.1-150400.17.12.1 SUSE-SU-2023:4988-1

Amazon Linux

ReleasePackageFixed inAdvisory
Amazon Linux 2023 python3-pip +1 21.3.1-2.amzn2023.0.7 ALAS2023-2023-442
Amazon Linux 2 python2-pip +2 20.2.2-1.amzn2.0.5 ALAS2-2023-2349

Azure Linux

ReleasePackageFixed inAdvisory
Azure Linux 3 python3 3.12.3-1 —
Azure Linux 2 (CBL-Mariner) python3 3.9.19-14 —

Wolfi

ReleasePackageFixed inAdvisory
Wolfi rolling jwt-tool 2.2.7-r0 —

Affected packages

EcosystemPackageAffectedFixedRecord
PyPI pip < 23.3 23.3 GHSA-mq26-g339-26xf

Advisories 15

References