in reply to Re: New to RegEx... need translation
in thread New to RegEx... need translation

die "weak password" if length($pw) < 8 or $pw !~ /[A-Z]/ or $pw !~ /[a-z]/ or $pw !~ /[0-9]/ or $pw !~ /[^a-z0-9]/i;
*cough* Ahem...

--
[ e d @ h a l l e y . c c ]

Replies are listed 'Best First'.
Re: Re: Re: New to RegEx... need translation
by Anonymous Monk on Apr 18, 2003 at 08:00 UTC
    *ehm* don't want to start a "perl gulf war", but one could have considered:
    $_ = $pw_candidate; die "weak password" if length < 8 and !/[A-Z]/ ...
    Murat