A simple, CLI-based Python tool to evaluate password strength based on entropy. It analyzes the variety and length of characters in a password and provides feedback and recommendations accordingly.
- Calculates password entropy using character pool and length.
- Classifies passwords as:
- β Too Weak
β οΈ Weak- π‘ Decent
- β Strong
- Offers actionable recommendations for improving password strength.
- No internet or external dependencies (other than Python standard library).
Entropy is a measure of unpredictability or randomness. In the context of passwords, higher entropy means it's harder for attackers to guess or brute-force your password.
Formula used:
Entropy = log2(pool_size) Γ password_length
git clone https://github.com/sinan-ashraf/password-checker.git
cd password-checker
python password_checker.py
Youβll see a prompt:
Enter password:
β just type in any password to test it.
Enter password: hello123
β Weak password (35.4 bits entropy)
Decent, but could be stronger.
Enter password: @G7vLp#2qR
β Strong password (64.2 bits entropy)
Strong password!
You can change the minimum acceptable entropy in the code:
MIN_ENTROPY = 30
Recommended values:
- 20+: Basic
- 30+: Good
- 40+: Strong