Skip to main content

A powerful but simple to use strong password generation library

Project description

Random password Generator

PyPI version Build Status Updates

A simple and custom random password generator.
  • Generate a simple password of default length 6-16.
  • Generate a password with custom properties.
  • Generate a password from given characters.
  • Generate Non Duplicate Password.
  • Available at https://random-pg.herokuapp.com/

API (GET Request)

  • Base_url: https://random-pg.herokuapp.com
  • Generate simple password /api/generate
    • Optional Attributes can be provided as params
      eg:
       /api/generate?minlen=16  
       /api/generate?minlen=16&minlchars=5
      
  • Generate a custom password from givin characters
    • Mandatory attributes can be provided as params
      eg:
       /api/shuffle?password=sdjbfbfB&maxlen=14
      
  • Generate a non duplicate password.
    • Mandatory Attribute 'maxlen'
      eg:
       /nonduplicate?maxlen=14
      

Usage

  • Install the package.
  • Import the package.
  • Create an instance
  • Modify the default properties. (Optional)
  • Generate the password (Default length of password 6-16 unless specified via properties).
  pip install random-password-generator
  from password_generator import PasswordGenerator

  pwo = PasswordGenerator()
  pwo.generate()

Configuration

property Description Default
minlen Minimum length of the password 6
maxlen Maximum length of the password 16
minuchars Minimum upper case characters required in password 1
minlchars Minimum lower case characters required in password 1
minnumbers Minimum numbers required in password 1
minschars Minimum special characters in the password 1

Update V2.1.0

Application uses secrets module instaed of random module whenever possible.

Update V2.0.1

Application is available at following link: https://random-pg.herokuapp.com/

Update V1.1.0

From version 1.1.0, Characters can be excluded from the required password by setting the properties on PasswordGenerator object

example:

  pwo = PasswordGenerator()

  pwo.excludeuchars = "ABCDEFTUVWXY" # (Optional)
  pwo.excludelchars = "abcdefghijkl" # (Optional)
  pwo.excludenumbers = "012345" # (Optional)
  pwo.excludeschars = "!$%^" # (Optional)

Generate a custom password

  pwo = PasswordGenerator()

  # All properties are optional
  pwo.minlen = 30 # (Optional)
  pwo.maxlen = 30 # (Optional)
  pwo.minuchars = 2 # (Optional)
  pwo.minlchars = 3 # (Optional)
  pwo.minnumbers = 1 # (Optional)
  pwo.minschars = 1 # (Optional)

  pwo.generate()

Generate a password from given characters

  pwo = PasswordGenerator()

  # It takes two arguments
  # required characters and length of required password
  pwo.shuffle_password('sdafasdf#@&^#&234u8', 20)

Generate Non Duplicate Password

  pwo = PasswordGenerator()

  # length of required password
  pwo.shuffle_password(20)

Contributions

Contributions are welcomed via PR.

License

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

easy-password-generator-0.0.2.tar.gz (2.9 kB view details)

Uploaded Source

Built Distribution

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

easy_password_generator-0.0.2-py3-none-any.whl (3.6 kB view details)

Uploaded Python 3

File details

Details for the file easy-password-generator-0.0.2.tar.gz.

File metadata

  • Download URL: easy-password-generator-0.0.2.tar.gz
  • Upload date:
  • Size: 2.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.9.1

File hashes

Hashes for easy-password-generator-0.0.2.tar.gz
Algorithm Hash digest
SHA256 333bd1157373d672dafafc5af416047614b823d3b19749005f6c6b970751c9a8
MD5 dc2b0ef3e432cbdcf8a22391d085e9d9
BLAKE2b-256 3d3b70f2bab9509112775b0501cd2e9e123117a39b6095339c25f50fa6257b56

See more details on using hashes here.

File details

Details for the file easy_password_generator-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: easy_password_generator-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.9.1

File hashes

Hashes for easy_password_generator-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4def3250c1d872a77b43a95ec820484a6f220a0027f72909342f33b2b95e18fc
MD5 287d40026c19a33224a349c987f0159b
BLAKE2b-256 d01c600682fcff6a9dd6e8b2fca3cb344b038c0fa67e74793b7ff14338c72d14

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