Skip to main content

papass is a simple library to generate passphrases and passwords.

Project description

papass

PyPI Documentation Status CI

papass generates passphrases following the diceware approach as proposed by Arnold G. Reinhold.

Quickstart

Assuming you have a wordlist file wordlist.txt (where to get one) you can run the following command to generate a random list of four words:

$ papass pp -l 4 -w wordlist.txt
Passphrase: grimy street acetone overcast
Entropy: 51.6993

By default this uses the system's most secure random number generator. To use physical dice add -r dice. The number of dice rolls can become very high so for convenience you can enter the rolls in groups as in the following example:

$ papass pp -l 4 -w wordlist.txt -r dice
Roll 20 dice: 5 1 3 5 1
Roll remaining 15 dice: 4 6 4 6 2
Roll remaining 10 dice: 5 6 2 3 6
Roll remaining 5 dice: 6 5 2 2 4
Passphrase: renegade reapprove static uphold
Entropy: 51.6993

Passwords can be created too (can also be used with -r dice):

$ papass pw -l 20 -p letters,digits
Password: rXJndFnML2j3YqVo2WgF
Entropy: 119.084

See papass.readthedocs.io for the full documentation.

Development

Create a virtual environment (e.g. via python -m venv .myvenv or mamba/micromamba). Install (development) dependencies and papass in editable mode:

$ pip install -r requirements.txt -e .

Run tests and type checking via

$ pytest
$ mypy

Formatting and linting is done via ruff.

$ ruff format
$ ruff check --fix

To build the docs install e.g. make and do

$ pip install -r docs/requirements.txt
$ make -C docs/ html

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

papass-0.0.5.tar.gz (28.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

papass-0.0.5-py3-none-any.whl (18.2 kB view details)

Uploaded Python 3

File details

Details for the file papass-0.0.5.tar.gz.

File metadata

  • Download URL: papass-0.0.5.tar.gz
  • Upload date:
  • Size: 28.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.32.3

File hashes

Hashes for papass-0.0.5.tar.gz
Algorithm Hash digest
SHA256 5dbaded27a0b944746074287d3651f3433fc9c47fdd60b7d0107db93130abe2b
MD5 8ff9219d97176c935b9a07b25899e5c9
BLAKE2b-256 3f5e220e71f51bd1ec3e2e35cc5264a861d7c752e829d31b84228e4803d0c78a

See more details on using hashes here.

File details

Details for the file papass-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: papass-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 18.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-requests/2.32.3

File hashes

Hashes for papass-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 cfc91455ead9527a8b829648a1067eb85dd1f1833124f23301544debe539dafb
MD5 3acf4c0e79ae5285b8fe989ea02f3826
BLAKE2b-256 2468ded3c05fe3d1313561d08454270fcd086ffa98347e4d3f62e6aa0307396b

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page