SecurityContext

CVE-2020-5252: Python Safety - Dependency Poisoning

  • Cve: CVE-2020-5252
  • Name: Python Safety - Dependency Poisoning
  • Description: The command-line "safety" package for Python has a potential security issue. There are two Python characteristics that allow malicious code to “poison-pill” command-line Safety package detection routines by disguising, or obfuscating, other malicious or non-secure packages. This vulnerability is considered to be of low severity because the attack makes use of an existing Python condition, not the Safety tool itself. This can happen if: You are running Safety in a Python environment that you don’t trust. You are running Safety from the same Python environment where you have your dependencies installed. Dependency packages are being installed arbitrarily or without proper verification. Users can mitigate this issue by doing any of the following: Perform a static analysis by installing Docker and running the Safety Docker image: $ docker run --rm -it pyupio/safety check -r requirements.txt Run Safety against a static dependencies list, such as the requirements.txt file, in a separate, clean Python environment. Run Safety from a Continuous Integration pipeline. Use PyUp.io, which runs Safety in a controlled environment and checks Python for dependencies without any need to install them. Use PyUp's Online Requirements Checker.
  • Impact: Attackers can potentially disguise malicious packages, leading to undetected security risks in dependency management.
  • Remediation: Run Safety in a trusted environment, use static analysis with Docker, or utilize CI/CD pipelines and PyUp's controlled tools for dependency checks.
  • Vulnerability impact: information_disclosure
  • Requirement type: none
  • Labels source: projectdiscovery
  • Severity: medium
  • Cvss score: 4.1
  • Cvss vector: CVSS:3.1/AV:L/AC:H/PR:H/UI:N/S:U/C:N/I:H/A:N
  • Epss score: 0.00366
  • Epss percentile: 0.31114
  • Assignee: [email protected]
  • Published at: 2020-03-23T23:15:12Z
  • Age in days: 2437
  • Modified at: 2026-06-17T03:21:08Z
  • References total: 3
  • Products total: 1
  • Oss: yes
  • Projects total: 1
  • Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2020-5252
  • Nvd status: modified
  • Checked, none or zero: patch available, known exploited entries, nuclei templates, public exploits total, public exploits capped, public exploits, rejected by nvd
  • Not known: vulnerability type, requirements, hackerone

Cwe

IdName
CWE-807Reliance on Untrusted Inputs in a Security Decision
NVD-CWE-noinfo—

References

Same in every row:

  • Source: nvd
UrlTags
https://pyup.io/posts/patched-vulnerability/Vendor Advisory
https://github.com/pyupio/safety/security/advisories/GHSA-7q25-qrjw-6fg2Mitigation, Third Party Advisory
https://github.com/akoumjian/python-safety-vulnProduct, Third Party Advisory

Products

ProductAffectedPlatform boundSourcesUrl
pyup:safety<= 1.8.6nonvd/v1/products/pyup/safety

Projects

RepositoryLink kindsIndexedUrl
pyupio/safetypackage, security_advisoryyes/v1/repositories/pyupio/safety

Index

  • Repositories: 26
  • Repositories high signal: 21
  • Packages: 1

Exploitation

  • Authentication required: yes
  • Checked, none or zero: known exploited, known exploited by, exploitation seen, public exploit, public exploit count, initial access, remote
  • Not known: known exploited since, vulncheck known exploited since, public exploit first date, nuclei template, initial access since, hackerone reports, exposed hosts