in reply to Regex usernames and Passwords

if ($user_pass =~ /^[A-Za-z0-9]+$/ && length($user_pass) < 17) { $user_pass = $1;

$1 won't contain anything unless you put some capturing parens in in the pattern.

Smylers