[PHP] Password Strength

Discussion in 'Web Design & Coding' started by Geffy, Aug 26, 2005.

  1. Geffy

    Geffy Moderator Folding Team

    Messages:
    7,805
    Location:
    United Kingdom
    I have spent the past day or so working on a PHP script to measure the strength of passwords.

    It uses four different measurements to build its final result. I would appreciate it some of you could look at it, test it with your own passwords and give me an idea of how accurate you think it is and so on.

    class.passwordstrength.php

    ideally you might test it in a script like this
    PHP:
    <?php
    require "class.passwordstrength.php";
    $ps = new PasswordStrength;

    $password "mypassword";
    $minimum_password_length 8;
    echo 
    "$password scores "$ps->score($password$minimum_password_length);
    ?>
    Please let me know what you think of it.