CVE-2013-5123: Insecure DNS Querying and Authenticity Checks in Python Pip

pip Updated 02 Oct 2025

Summary

05/11/2019
Yes i
High
5.9

CVE-2013-5123: The mirroring support (-M, --use-mirrors) in Python Pip before 1.5 uses insecure DNS querying and authenticity checks which allows attackers to perform man-in-the-middle attacks. Affects pip versions < 1.5. Fixed in 1.5. How to fix ↓

Also tracked for

The same CVE-2013-5123 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

Python Pip is a package management system used to install and manage software packages written in Python. It allows users to easily install, upgrade, and remove Python packages. Pip is widely used in the Python ecosystem and is an essential tool for developers and system administrators.

Vulnerability Detail

The mirroring support (-M, --use-mirrors) in Python Pip before version 1.5 uses insecure DNS querying and authenticity checks. This vulnerability allows attackers to perform man-in-the-middle attacks. By intercepting the DNS queries made by Pip, an attacker can redirect the package download requests to a malicious mirror server. This can lead to the installation of compromised or malicious packages, potentially compromising the integrity and security of the Python environment.

How To Fix

Latest published version: 26.2.2 as of 22 Oct 2026

pip install --upgrade "pip==26.2.2"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.5

This is the first release that contains the fix.

pip install --upgrade "pip==1.5"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is crucial to upgrade Pip to the fixed version to mitigate the risk of man-in-the-middle attacks.

Conclusion

In conclusion, the vulnerability (CVE-2013-5123) in Python Pip allows for man-in-the-middle attacks due to insecure DNS querying and authenticity checks. To mitigate this risk, it is essential to upgrade Pip to version 1.5 or later. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for pip →

Share this vulnerability

FAQ

Python Pip is a package management system used to install and manage software packages written in Python.

This vulnerability allows attackers to perform man-in-the-middle attacks, potentially leading to the installation of compromised or malicious packages.

To fix this vulnerability, upgrade Python Pip to version 1.5 or later by running 'pip install --upgrade pip'.

There is no known workaround for this vulnerability. It is crucial to upgrade Pip to the fixed version.

Related vulnerabilities

Recent vulnerabilities recorded for pip.

How To Fix

Latest published version: 26.2.2 as of 22 Oct 2026

pip install --upgrade "pip==26.2.2"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.5

This is the first release that contains the fix.

pip install --upgrade "pip==1.5"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback