Skip to content

garrywashere/password-generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 

Repository files navigation

Simple Password Generator

Just a simple password generator, written in Python 🐍.

Why?

I was bored.

Overview

This Python script provides a simple password generator that allows users to specify the desired length and strength of the generated password. The generator ensures a mix of lowercase letters, uppercase letters, digits, and special characters, meeting the specified strength criteria.

Features

  • Generates random passwords based on user-defined length and strength.
  • Incorporates a mix of lowercase letters, uppercase letters, digits, and special characters for enhanced security.

Usage

  1. Clone the repository:

    git clone https://github.com/garrywashere/password-generator.git
  2. Navigate to the project directory:

    cd password-generator
  3. Import the script in your program:

    from password_generator import Generator
    gen = Generator()
    
    new_password = gen.generate(8, 1)
  4. The generated password will be returned.

    • The length parameter determines the total number of characters in the password (minimum strength * 4)
    • The strength parameter determines the minimum number of each type of character included in the password. Example:
    •  gen.generate(4, 1)
       # At least one of each type of character is used
       '8-vR'
    •  gen.generate(8, 2)
       # At least two of each type of character are used
       'g_9z2XU^'

About

Simple Password Generator in Python

Topics

Resources

Stars

Watchers

Forks

Languages