Skip to main content

Safe

Is your password safe? Safe will check the password strength for you.

https://travis-ci.org/lepture/safe.png?branch=master

How it works

Safe will check if the password has a simple pattern, for instance:

  1. password is in the order on your QWERT keyboards.

  2. password is simple alphabet step by step, such as: abcd, 1357

Safe will check if the password is a common used password. Many thanks to Mark Burnett for the great work on 10000 Top Passwords.

Safe will check if the password has mixed number, alphabet, marks.

Installation

Install Safe with pip:

$ pip install Safe

If pip is not available, try easy_install:

$ easy_install Safe

Usage

It’s very simple to check the strength of a password:

>>> import safe
>>> safe.check(1)
terrible
>>> safe.check('password')
simpile
>>> safe.check('is.safe')
medium
>>> safe.check('x*V-92Ba')
strong
>>> strength = safe.check('x*V-92Ba')
>>> bool(strength)
True
>>> repr(strength)
'strong'
>>> str(strength)
'password is perfect'
>>> strength.valid
True
>>> strength.strength
'strong'
>>> strength.message
'good password'

Environ Variables

  1. PYTHON_SAFE_WORDS_CACHE: cache words in this file, default is a tempfile

  2. PYTHON_SAFE_WORDS_FILE: words vocabulary file, default is the 10k top passwords

Other Implementations

  1. JavaScript: lepture/safe.js

Metadata

Release files for Safe 0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Safe 0.4
File Size Uploaded
Safe-0.4.tar.gz 56.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for Safe 0.4
File Interpreter ABI Platform
Safe-0.4-py2-none-any.whl Python 2 none any Details

Total release size: 112.8 kB

Release files / Safe-0.4.tar.gz

Download URL Safe-0.4.tar.gz
Size 56.8 kB
Tags Source
SHA-256 checksum
How to use checksums
a2fdac9fe8a9dcf02b438201d6ce0b7be78f85dc6492d03edfb89be2adf489de
BLAKE2b-256 checksum
How to use checksums
d23dea0fa7a262431f4b94845df59637bbb4ccac9d03a696ca1d894631da8614
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / Safe-0.4-py2-none-any.whl

Download URL Safe-0.4-py2-none-any.whl
Size 56.0 kB
Tags Python 2
SHA-256 checksum
How to use checksums
4e7315087d80fdbbc781362a656376cfa273c5c68a8abc0412e159bf541fcbda
BLAKE2b-256 checksum
How to use checksums
6e1928e04729954cd3c401ad09aabf14bf896a9e5b112f7d56bc7ea2617a7b36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.4 This release

2 release files

0.3

1 release file

0.2

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page