Name | Date | Size | #Lines | LOC | ||
---|---|---|---|---|---|---|
.. | 03-May-2022 | - | ||||
Safe.egg-info/ | H | 03-May-2022 | - | 99 | 77 | |
safe/ | H | 08-Nov-2015 | - | 10,234 | 10,163 | |
LICENSE | H A D | 22-Jul-2014 | 1.5 KiB | 28 | 23 | |
MANIFEST.in | H A D | 23-Jul-2014 | 58 | 4 | 3 | |
PKG-INFO | H A D | 08-Nov-2015 | 3.2 KiB | 99 | 77 | |
README.rst | H A D | 28-Jul-2014 | 1.6 KiB | 72 | 51 | |
setup.cfg | H A D | 08-Nov-2015 | 59 | 6 | 4 | |
setup.py | H A D | 22-Jul-2014 | 1.6 KiB | 62 | 50 |
README.rst
1Safe 2==== 3 4Is your password safe? **Safe** will check the password strength for you. 5 6.. image:: https://travis-ci.org/lepture/safe.png?branch=master 7 :target: https://travis-ci.org/lepture/safe 8 9How it works 10------------ 11 12**Safe** will check if the password has a simple pattern, for instance: 13 141. password is in the order on your QWERT keyboards. 152. password is simple alphabet step by step, such as: abcd, 1357 16 17**Safe** will check if the password is a common used password. 18Many thanks to Mark Burnett for the great work on `10000 Top Passwords <https://xato.net/passwords/more-top-worst-passwords/>`_. 19 20**Safe** will check if the password has mixed number, alphabet, marks. 21 22Installation 23------------ 24 25Install Safe with pip:: 26 27 $ pip install Safe 28 29If pip is not available, try easy_install:: 30 31 $ easy_install Safe 32 33Usage 34----- 35 36It's very simple to check the strength of a password:: 37 38 >>> import safe 39 >>> safe.check(1) 40 terrible 41 >>> safe.check('password') 42 simpile 43 >>> safe.check('is.safe') 44 medium 45 >>> safe.check('x*V-92Ba') 46 strong 47 >>> strength = safe.check('x*V-92Ba') 48 >>> bool(strength) 49 True 50 >>> repr(strength) 51 'strong' 52 >>> str(strength) 53 'password is perfect' 54 >>> strength.valid 55 True 56 >>> strength.strength 57 'strong' 58 >>> strength.message 59 'good password' 60 61 62Environ Variables 63----------------- 64 651. **PYTHON_SAFE_WORDS_CACHE**: cache words in this file, default is a tempfile 662. **PYTHON_SAFE_WORDS_FILE**: words vocabulary file, default is the 10k top passwords 67 68Other Implementations 69--------------------- 70 711. **JavaScript**: `lepture/safe.js <https://github.com/lepture/safe.js>`_ 72