Generate secure multiword passwords/passphrases, inspired by XKCD
Project description
xkpassgen
A flexible and scriptable password generator which generates strong passphrases, inspired by XKCD 936
$ xkpassgen
> HeadscarfSuddenDumping93
Install
xkpassgen
can easily be installed with the following command:
pip install xkpassgen
or manually by:
python setup.py install
Source
The source code can be found here.
Contributions welcome and gratefully appreciated!
Requirements
Python 3 (Version 3.6 or later).
Running xkpassgen
xkpassgen
can be called with no arguments with an output using the default wordfile and settings.
$ xkpassgen
> HeadscarfSuddenDumping93
The default settings return a single password made up of 3 words each having its first letter capitalized with two random digits afterwards.
It can also be called with a mixture of multiple arguments for example:
$ xkpassgen -d _ -c 5 --min 5 --max 7 --padding-digits-num 4
> Mundane_Music_Spleen1837
> Reuse_Acclaim_Clarify2492
> Wildly_Contest_Anchor1798
> Imprint_Luster_Happy4339
> Scarf_Strobe_Footer5579
This will return:
-d _
words joined by_
.-c 5
5 passwords to choose from.--min 5 --max 7
words between 5 and 7 characters long.--padding-digits-num 4
4 digits on the end of the password.
A full overview of the available options can be accessed by running following command:
xkpassgen --help
Word Lists
Several word lists are provided with the package. The default, eff-long, was specifically designed by the EFF for passphrase generation and is licensed under CC BY 3.0. As it was originally intended for use with Diceware ensure that the number of words in your passphrase is at least six when using it. Two shorter variants of that list, eff-short and eff-special, are also included. Please refer to the EFF documentation linked above for more information.
Note that xkpassgen
can be used with any word file of the correct format: a file containing one word per line.
Changelog
- Version 1.0.0
- Initial Release
- Version 1.0.1
- Fixed license display on PyPI.
- Fixed links to license files on PyPI.
- Version 1.0.2
- Fix interactive usage.
- Fix issue where wrong wordfile wasn't being recognised.
- Add 100% test coverage.
- Version 1.0.5
- Fix typo in static import causing wordfile error.
License
This project is released under the GNU GENERAL PUBLIC LICENSE v3. However the original code from redacted/XKCD-password-generator is licensed under the BSD 3-Clause license.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for xkpassgen-1.0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8b5fd6aa5d980602069771385c00521a6693c07ae26d5932ea90b9af89cc7797 |
|
MD5 | 415395c7a5d7d4c97196f013def61df5 |
|
BLAKE2b-256 | fce2cf18fef08dbf5c443c4b1277005485f130bc4b2656920ece8403bad28000 |