CVE-2013-5123: Pip Improper Authentication Vulnerability

HIGH
Advisory Identifier: GHSA-c5h8-cq4v-cvfm
CVSS 5.9
CWE-287
Published
Advisory Summary

CVE-2013-5123 is a HIGH (CVSS 5.9) improper authentication vulnerability (CWE-287: Improper Authentication) affecting Pip libraries in the PyPI ecosystem. The issue involves improper authentication in pip. Remediation is available by upgrading affected packages to version 1.5.

CVE-2013-5123 at a Glance

CVE Identifier CVE-2013-5123
GHSA Identifier GHSA-c5h8-cq4v-cvfm
Severity HIGH
CVSS v3.1 Base Score 5.9
CWE Classification CWE-287: Improper Authentication
Affected Product Pip
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 5.9

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity High (I:H)
Availability None (A:N)

How to Fix CVE-2013-5123

To remediate this vulnerability, upgrade all affected Pip dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

pip fixed: 1.5
pip install pip>=1.5
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show pip

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2013-5123, inspect your installed packages using pip:

pip show pip

Analyze the terminal output to locate any version of Pip in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.5), your application is affected.

Note: The pip show pip command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-287: Improper Authentication, where when an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct. In Pip, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

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.

CVE-2013-5123 Affected Pip Versions

1 component(s)
Fixed Versions:
1.5
Product / Package Ecosystem Affected Versions Fixed Version
pip
PyPI
< 1.5
1.5

References

Frequently Asked Questions

What is CVE-2013-5123?
CVE-2013-5123 is a security vulnerability in Pip involving Improper Authentication in pip under CWE-287: Improper Authentication.
Which Pip versions are affected?
Affected versions include releases prior to 1.5 across affected packages: pip.
What version fixes CVE-2013-5123?
Upgrading to 1.5 (or the latest patched release for your respective branch) resolves the vulnerability.
Is pip affected?
Yes, pip is affected in releases prior to 1.5. Upgrade your dependency to 1.5 or later.
What is the CVSS score of CVE-2013-5123?
CVE-2013-5123 has a CVSS v3.1 base score of 5.9 (HIGH) with vector string CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N.
What CWE is associated with CVE-2013-5123?
CVE-2013-5123 is classified under CWE-287: Improper Authentication (When an actor claims to have a given identity, the product does not prove or insufficiently proves that the claim is correct.).
How can I check PyPI dependencies for CVE-2013-5123?
Run the dependency tree command: 'pip show pip'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-c5h8-cq4v-cvfm",
  "modified" : "2024-10-14T21:49:09Z",
  "published" : "2022-05-24T22:01:03Z",
  "aliases" : [ "CVE-2013-5123" ],
  "summary" : "Improper Authentication in pip",
  "details" : "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.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "pip"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.5"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2013-5123"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2013-5123"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.suse.com/show_bug.cgi?id=CVE-2013-5123"
  }, {
    "type" : "ADVISORY",
    "url" : "https://github.com/advisories/GHSA-c5h8-cq4v-cvfm"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/pip/PYSEC-2019-160.yaml"
  }, {
    "type" : "WEB",
    "url" : "https://security-tracker.debian.org/tracker/CVE-2013-5123"
  }, {
    "type" : "WEB",
    "url" : "http://lists.fedoraproject.org/pipermail/package-announce/2015-April/155248.html"
  }, {
    "type" : "WEB",
    "url" : "http://lists.fedoraproject.org/pipermail/package-announce/2015-April/155291.html"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2013/08/21/17"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2013/08/21/18"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-287" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2022-07-07T23:28:34Z",
    "nvd_published_at" : "2019-11-05T22:15:00Z"
  }
}