Re[2]: [PHP] help needed with crypt()

2002-12-03 Thread Tom Rogers
Hi, Wednesday, December 4, 2002, 1:27:49 AM, you wrote: cyc> Hi cyc>I made some changes to this script but still it is cyc> not working Try using the whole password as the salt like this if(crypt(trim($pass),$arr[1]) == $arr[1]) Or are you still only getting -1 returned ? -- regards, T

Re: [PHP] help needed with crypt()

2002-12-03 Thread chandrakantreddy
Hi I made some changes to this script but still it is not working > > cyc>function authenticate($user,$pass) { > cyc> $result = -1; > cyc> $data = file("shadow"); /* permission > every > cyc> one read */ > > cyc> foreach($data as $line ) { > cyc> $

Re: [PHP] help needed with crypt()

2002-12-03 Thread Tom Rogers
Hi, Wednesday, December 4, 2002, 12:45:15 AM, you wrote: cyc> Hi cyc> The script is not working. cyc>function authenticate($user,$pass) { cyc> $result = -1; cyc> $data = file("shadow"); /* permission every cyc> one read */ cyc> foreach($date as $line ) { cyc>

[PHP] help needed with crypt()

2002-12-03 Thread chandrakantreddy
Hi The script is not working. function authenticate($user,$pass) { $result = -1; $data = file("shadow"); /* permission every one read */ foreach($date as $line ) { $arr = explode(":",$line); if($arr[0] == $user) { /* user