Skip to content

This project tests the strength of passwords, intended to be used alongside goated-password-manager

Notifications You must be signed in to change notification settings

elliotsyun/goated-strength-tester

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 

Repository files navigation

Goated Strength Tester

# Password Strength Evaluator

This repository provides functions to evaluate the strength of a password based on entropy calculations and character composition. It also includes functions to check if a password meets specific criteria and if it is a commonly used password.

## Table of Contents

- [Installation](#installation)
- [Usage](#usage)
  - [Entropy Checker](#entropy-checker)
  - [Password Strength Checker](#password-strength-checker)
- [Testing](#testing)
- [Examples](#examples)
- [Author](#author)

## Installation

Clone the repository:

```bash
git clone https://github.com/elliotsyun/goated-strength-tester.git
cd password-strength-evaluator

Install the required dependencies:

pip install -r requirements.txt

Usage

Entropy Checker

The entropy checker evaluates the strength of a password based on entropy calculations and character composition.

Functions

  • find_pool(password): Determines the size of the character pool based on the types of characters in the password.
  • entropy_test(pool, password): Calculates the entropy of the password and classifies its strength.

Password Strength Checker

The password strength checker tests the strength of a password based on criteria such as length, use of special characters, and common password checks.

Functions

  • strength_len_char(password): Checks the length of the password to ensure it is at least 11 symbols and verifies the use of uppercase letters, lowercase letters, numbers, and special characters.
  • check_comm(password): Checks that the password is not a commonly used password by comparing it against a list in 'common_passwords.txt'.

Testing

Unit tests are provided for the functions using pytest. To run the tests, navigate to the root directory of the project and execute:

pytest tests

Examples

Entropy Checker

To determine the character pool size of a password:

from src.entropy_checker import find_pool

pool_size = find_pool("StrongPass123!")
print(pool_size)

To calculate the entropy of a password and classify its strength:

from src.entropy_checker import entropy_test

pool_size = find_pool("StrongPass123!")
entropy = entropy_test(pool_size, "StrongPass123!")
print(entropy)

Password Strength Checker

To check if a password meets the required strength criteria:

from src.pass_strength import strength_len_char

is_strong = strength_len_char("StrongPass123!")
print(is_strong)

To verify that a password is not a commonly used one:

from src.pass_strength import check_comm

is_unique = check_comm("password123")
print(is_unique)

Author

Elliot Yun

Date: 2024-07-12

Version: 1.0.3

About

This project tests the strength of passwords, intended to be used alongside goated-password-manager

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages