Skip to main content

A curated database of insecure Python packages

Project description


What is Safety DB?

Safety DB is a database of known security vulnerabilities in Python packages. The data is made available by and synced with this repository once per month. Most of the entries are found by filtering CVEs and changelogs for certain keywords and then manually reviewing them.


  • Safety CI is a deep GitHub integration that's available on It checks your commits and Pull Requests.
  • Safety is a command line tool that checks virtualenvironments and requirement files either locally or on a CI server.
  • Safety Django is a package for Django that warns you in the admin area if your installed Django release is insecure.
  • Safety Bar (alpha) is a macOS menubar application.
  • A pre-commit hook by Lucas Cimon.
  • pipenv check relies on safety and Safety-DB to check for known vulnerabilities in locked components
  • your tool?


pip install safety-db


from safety_db import INSECURE, INSECURE_FULL

What is this not?

This is not a hall of shame, or a list of packages to avoid. The package maintainers show a great responsibility by documenting and fixing security issues in such a way that they can be listed here. That's extremely valuable when considering using a package in production.

Using this data

For humans:

For robots:

Check out the data directory:

  • insecure.json contains just the package name and all insecure releases as a plain list.
  • insecure_full.json additionally contains the CVE description and URLs, or the relevant part of the changelog.

The database is licensed under CC BY-NC-SA 4.0. This allows you to use the data in any non commercial project as long as you link back to this repo. If you need a license for a commercial project, please contact

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

safety-db-2021.7.17.tar.gz (290.5 kB view hashes)

Uploaded source

Built Distribution

safety_db-2021.7.17-py2.py3-none-any.whl (244.5 kB view hashes)

Uploaded py2 py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page