An open API service indexing awesome lists of open source software.

https://github.com/a3ro-dev/password_generator

Python program that generates a random password with the specified length, inserts it into a database, and then checks if the generated password already exists in the database. If it does, the program generates a new password and repeats the process until it generates a unique password.
https://github.com/a3ro-dev/password_generator

database generator password password-generator password-manager project-python security

Last synced: 6 months ago
JSON representation

Python program that generates a random password with the specified length, inserts it into a database, and then checks if the generated password already exists in the database. If it does, the program generates a new password and repeats the process until it generates a unique password.

Awesome Lists containing this project

README

          

# Password Generator

This is a Python program that generates random passwords of a specified length and stores them in a database to ensure that each generated password is unique.

## Requirements

- Python 3
- sqlite3

## Usage

To use the password generator, run the `password_generator.py` file in Python. The program will prompt you to enter the desired password length, and then it will generate a random password of that length. If the generated password already exists in the database, the program will generate a new password until it generates a unique one.

The generated password will be output to the user and also stored in the `passwords` table of the `passwords.db` SQLite database.

## Notes

- The `passwords.db` database must be located in the `db` directory. If the database does not exist, it will be created when the program is run for the first time.
- The `passwords` table in the database must have a single `password` column of type `text`. If the table does not exist, it will be created when the program is run for the first time.

## Example

```bash
Enter the desired password length: 12
Your generated password is: cOZa2dQIxzvb
```