pears crypt to php

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View
I have a set of passwords encrypted using perls crypt, from a perl
forum being migrated to php.

I like to bring them into php, and use them without changing them.  
How do I emulate perls crypt function.

I found a pear module here:
but it seems to only take one argument, whereas perls crypt should
take two args (?).

Please help.


Posted using the interface, at author's request
Articles individually checked for conformance to usenet standards
Topic URL:
Visit Topic URL to contact author (reg. req'd).  Report abuse:

Re: pear's crypt to php

steve wrote:
Quoted text here. Click to load it

Using Perl:

my $string = 'the string';
my $salt = 'secret';

print crypt $string, $salt; # Prints sewZw1OY/.llM

Using :

$string = 'the string';
$salt = 'secret';

print crypt($string, $salt); # Prints sewZw1OY/.llM


Site Timeline