Re: [PHP] User Passwords: checking for unique chars

2005-02-23 Thread Jochem Maas
Richard Lynch wrote: Jochem Maas wrote: Alex Gemmell wrote: On Mon, 14 Feb 2005 22:51:42 +0100, Jochem Maas [EMAIL PROTECTED] wrote: Alex Gemmell wrote: #Contain at least one number if ( !preg_match ('/\\d/', $password) ) return false; Im pretty sure the double backslash is a typo. nice

Re: [PHP] User Passwords: checking for unique chars

2005-02-15 Thread Burhan Khalid
[ snipped ] Oh! You're so mean!! ;) A lot of people are making some great points. I feel I must strighten this out a little. While I may not be the best coder in the world I do have my reasons. I originally made the passwords automatically generated and emailed to the user. Nice complicated

Re: [PHP] User Passwords: checking for unique chars

2005-02-15 Thread Richard Lynch
Jochem Maas wrote: Alex Gemmell wrote: On Mon, 14 Feb 2005 22:51:42 +0100, Jochem Maas [EMAIL PROTECTED] wrote: Alex Gemmell wrote: #Contain at least one number if ( !preg_match ('/\\d/', $password) ) return false; Im pretty sure the double backslash is a typo. No, it's *NOT* a

[PHP] User Passwords: checking for unique chars

2005-02-14 Thread Alex Gemmell
Hello! I'm checking user chosen passwords for validity and have created 7 tests. It's not 100% bulletproof but it will do for now. My problem is with the last check have 6 unique characters. I'm at a loss at how to check for this in a neat one-liner. My brain is starting to go off on some

RE: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Mike Johnson
From: Alex Gemmell [mailto:[EMAIL PROTECTED] Hello! I'm checking user chosen passwords for validity and have created 7 tests. It's not 100% bulletproof but it will do for now. My problem is with the last check have 6 unique characters. I'm at a loss at how to check for this in a neat

Re: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Richard Lynch
Alex Gemmell wrote: I'm checking user chosen passwords for validity and have created 7 tests. It's not 100% bulletproof but it will do for now. My problem is with the last check have 6 unique characters. I'm at a loss at how to check for this in a neat one-liner. if

Re: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Alex Gemmell
Wow - good job! That nailed it and in one neat line too! Thanks very much Richard and thanks also to Mike for his help too. I'm really liking these php lists! On Mon, 14 Feb 2005 09:41:00 -0800 (PST), Richard Lynch [EMAIL PROTECTED] wrote: Alex Gemmell wrote: I'm checking user chosen

RE: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Chris W. Parker
Alex Gemmell mailto:[EMAIL PROTECTED] on Monday, February 14, 2005 7:24 AM said: Hello! Hi! # Code: beingfunnynotmean!Do you also have a label on your computer that says Computer?/beingfunnynotmean! Some questions (because I'm curious): 1. Why would you *not* allow

Re: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Jason Barnett
Chris W. Parker wrote: Alex Gemmell mailto:[EMAIL PROTECTED] on Monday, February 14, 2005 7:24 AM said: Hello! Hi! Bonjour! # Code: beingfunnynotmean!Do you also have a label on your computer that says Computer?/beingfunnynotmean! No, but I do have a label that says My

Re: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Alex Gemmell
On Mon, 14 Feb 2005 10:17:53 -0800, Chris W. Parker [EMAIL PROTECTED] wrote: Alex Gemmell mailto:[EMAIL PROTECTED] on Monday, February 14, 2005 7:24 AM said: Hello! Hi! # Code: beingfunnynotmean!Do you also have a label on your computer that says

Re: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Jochem Maas
Alex Gemmell wrote: Hello! I'm checking user chosen passwords for validity and have created 7 tests. It's not 100% bulletproof but it will do for now. My problem is with the last check have 6 unique characters. I'm at a loss at how to check for this in a neat one-liner. My brain is starting to

Re: [PHP] User Passwords: checking for unique chars

2005-02-14 Thread Jochem Maas
Alex Gemmell wrote: On Mon, 14 Feb 2005 22:51:42 +0100, Jochem Maas [EMAIL PROTECTED] wrote: Alex Gemmell wrote: ... #Contain at least one number if ( !preg_match ('/\\d/', $password) ) return false; Im pretty sure the double backslash is a typo. here are some regexps from a php5 class