I Built a Password Strength Checker - My First Security Tool
Why I built this
Year 2 Cybersecurity, just finished TryHackMe Pre Security. I wanted a small win before jumping into IoT Lab.
Workflow I use: GitHub = code + overview, Hashnode = detailed story.
What it checks
A strong password is defined as one with length >=8, uppercase, lowercase, digit, special char. I also check common passwords.
Length >= 8
Uppercase (A-Z), lowercase (a-z)
Digit (0-9)
Special char (#?!@$%^&*-)
Not in common list: password, 123456, qwerty
Code
Full code: github.com/donottreadmyname/small-security-projects/tree/main/01-password-checker
Key snippet:
import re
if re.search(r"[A-Z]", password):
score += 1
if re.search(r"[#?!@$%^&*\-]", password):
score += 1
