[nycphp-talk] Crypt issue??
Jeff
jsiegel1 at optonline.net
Fri Jun 6 22:39:11 EDT 2003
Thanks for your input but as I noted in a subsequent post
(actually...the answer came to me 30 seconds after shooting out the
email)....it was really a darned typo that caused the error!
I did exactly as you suggested...put in an echo statement...that's when
the light bulb went off (or was it the dope slap?).
What's the advantage of MD5 vis-a-vis crypt?
Jeff
-----Original Message-----
From: Analysis & Solutions [mailto:danielc at analysisandsolutions.com]
Sent: Friday, June 06, 2003 8:15 PM
To: NYPHP Talk
Subject: Re: [nycphp-talk] Crypt issue??
Hey Jeff:
On Fri, Jun 06, 2003 at 05:37:27PM -0400, Jeff wrote:
> When it encodes the password '12345' when adding the record it
generates
> "WOjDi2e3GGR4U"
> But when I test the login function it generates "WOxvmVFSIQUTU"
>
> In both cases I'm using this to call the function:
> $tmpPwd = EncryptString($_POST['DU_sPwd']);
Is this user creation and login procedures contained in the same script?
If not, is the EncryptString() function EXACTLY the same in each script,
including the same salt?
You might want to simplify things by using md5().
Anyway, put an echo statement inside the function:
echo ">$stringtoencrypt<";
and see if the actual input is the same. Perhaps something is modifying
your input before it gets submitted to the function.
Enjoy,
--Dan
--
FREE scripts that make web and database programming easier
http://www.analysisandsolutions.com/software/
T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y
4015 7th Ave #4AJ, Brooklyn NY v: 718-854-0335 f: 718-854-0409
--- Unsubscribe at http://nyphp.org/list/ ---
More information about the talk
mailing list