Navigation

Pligg Support

Anybody know how to change the register password length limit? It is currently set to a minimum of 5 and I would like to change this plus maybe add in other criteria: numbers, letters, uppercase, lowercase.
Thanks
PAul

Possible Answers

    Mmmm, not exactly the answere I was looking, rather I wanted to know ehger in the numerous system files was the password length conntrolled. However i found it in register.php, line 123 has the following code

    if(strlen($password) < 5 ) { // if password is less than 5 characters

    $form_password_error[] = $main_smarty->get_config_vars('PLIGG_Visual_Register_Error_FiveCharPass');

    $error = true;

    This looks like the rigth place to me, chaning the 5 to a 10 should do the trick, adding further format restrictions should be fairly staright forward.

    Thanks

    Paul

    | Posted 134 days ago | Permalink | Hide Replies

    Not exactly the answer I was looking for, rather where in the numerous files I could find out where the limit is controlled. However, I found what I was looking for in register.php, around line 123 it has the following code:

    if(strlen($password) < 5 ) { // if password is less than 5 characters

    $form_password_error[] = $main_smarty->get_config_vars('PLIGG_Visual_Register_Error_FiveCharPass');

    $error = true;

    I'm guessing that changing the '5' to say 10 will do the trick.

    Thanks

    Paul

    | Posted 134 days ago | Permalink | Hide Replies

    Oh, yeah, if you do change just the length, don't forget to change the language file for the error. Else your users will see the current "Password Length" error which may confuse them if they already used 5 letters/numbers but the script requires more. They may give up instead of adding more characters.

    | Posted 134 days ago | Permalink | Hide Replies

    That will take care of New Registrations but not the old Users and Passwords.

    I was thinking about an across the board fix using the built-in Pligg 'hooks' (if they are there) with stuffing in the JavaScript if you find one. That would get you through upgrades of software and maybe template changes, too.

    Also, I was thinking you wanted more than just a length change..... A mix of caps, numbers, etc.

    | Posted 134 days ago | Permalink | Hide Replies

    Never gave this any thought but I bet there's a Javascript somewhere you could drop into the login template that would force a tougher Password according to your parameters and requirements.

    | Posted 135 days ago | Permalink | Hide Replies

Who Upvoted this Story