Password Strength Checker

    0

    0

    Aakanksha Priya

    from password_strength import PasswordPolicy
    
    policy = PasswordPolicy.from_names(
        length=8,  # min length: 8
        uppercase=2,  # need min. 2 uppercase letters
        numbers=2,  # need min. 2 digits
        special=2,  # need min. 2 special characters
        nonletters=2,  # need min. 2 non-letter characters (digits, specials, anything)
    )
    def password(p):
        res = policy.test(p)
        if (res):
            print("Strong Password")
        else:
            print("Weak Password")
        return 
    # Main method
    psw = input("Enter password: ")
    password(psw)
    
    Codiga Logo
    Codiga Hub
    • Rulesets
    • Explore
    • Cookbooks
    • Playground
    soc-2 icon

    We are SOC-2 Compliance Certified

    G2 high performer medal

    Codiga – All rights reserved 2022.