crypt problem

This is a discussion on crypt problem within the PHP General forums, part of the PHP Programming Forums category; Hi, I have a weird problem with the crypt function. If I do: <?php echo(CRYPT_SALT_LENGTH); echo(CRYPT_MD5); echo ...


Go Back   Usenet Forums > PHP Programming Forums > PHP General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 09-11-2003
Serge Grondin
 
Posts: n/a
Default crypt problem

Hi,

I have a weird problem with the crypt function.

If I do:
<?php
echo(CRYPT_SALT_LENGTH);
echo(CRYPT_MD5);
echo crypt("xxxxxxxx", 'aa');
echo crypt("xxxxxxxx", '$1$kTzSYf0n$');
?>

It print:

12 1 aat2dQ.feSqBI $1qjC9EADQ1x6


It seem that the second password is not encrypted in MD5 but with DES.
It should be in MD5 if I read the doc correctly.

My PHP version is 4.3.1 and compiled on a RedHat 7.3 with the 2.4.18-27
kernel, apache 1.3.27 and the configure string:

'./configure' '--with-mysql' '--with-apache=../apache' '--with-gettext'
'--with-xml' '--with-dom' '--with-imap=../imap' '--enable-mime-magic'
'--with-iconv' '--enable-mbstring' '--with-zlib' '--enable-calendar'
'--with-imap-ssl' '--with-mcrypt'

Is it something I do wrong or something wrong in my system?

Thank you.
--
Serge Grondin
Technicien en Informatique
Commission Scolaire des Bois-Francs
Tel. bur.: (819) 758-6453, poste 2920
e-Mail bur.: SGrondin@csbf.qc.ca
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 06:10 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0