[PHP] MD5 System Password check with PHP

2003-08-26 Thread Chinmoy Barua
Hello everybody,

I want to authenticate my user from web with PHP
script. The user's passwords are stored in System as
MD5 format (in /etc/shadow). 

Can anybody help me?

- Chinmoy


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] MD5 System Password check with PHP

2003-08-26 Thread murugesan
First store the password in the DB as 
$passwd=md5($passwd)
insert into table values( $passwd);

get the user password and check by comparing
if(md5($password)==$fetchedpasswdfromDB)
{
...
}

-murugesan

- Original Message - 
From: Chinmoy Barua [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 26, 2003 11:34 AM
Subject: [PHP] MD5 System Password check with PHP


 Hello everybody,
 
 I want to authenticate my user from web with PHP
 script. The user's passwords are stored in System as
 MD5 format (in /etc/shadow). 
 
 Can anybody help me?
 
 - Chinmoy
 
 
 __
 Do you Yahoo!?
 Yahoo! SiteBuilder - Free, easy-to-use web site design software
 http://sitebuilder.yahoo.com
 
 -- 
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 
 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] MD5 System Password check with PHP

2003-08-26 Thread Justin French
On Tuesday, August 26, 2003, at 04:04  PM, Chinmoy Barua wrote:

Hello everybody,

I want to authenticate my user from web with PHP
script. The user's passwords are stored in System as
MD5 format (in /etc/shadow).
Can anybody help me?
Which part do you want help with?

The form?
The SQl query?
The whole lot?
My guess is the query

$sql = 
SELECT id
FROM users
WHERE username='.$_POST['username']}'
AND password='.md5($_GET['password']).';
It (MD5) can also be done directly in the query as a MySQL function.

Justin

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] MD5 System Password check with PHP

2003-08-26 Thread Burhan
Quoting Justin French [EMAIL PROTECTED]:

 On Tuesday, August 26, 2003, at 04:04  PM, Chinmoy Barua wrote:
 
  Hello everybody,
 
  I want to authenticate my user from web with PHP
  script. The user's passwords are stored in System as
  MD5 format (in /etc/shadow).
 
  Can anybody help me?

See http://www.zend.com/zend/tut/authentication.php

-- 
Burhan
phplist[at]meidomus[dot]com
http://www.meidomus.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] MD5 System Password check with PHP

2003-08-26 Thread Justin French
Burhan,

Please try to quote the right person when replying to a thread -- your 
messages was, I assume, intended for Chinmoy Barua, not me.

It saves confusion, and keeps the thread more useful and easier to 
follow.

Thanks,
Justin French
On Tuesday, August 26, 2003, at 04:17  PM, Burhan wrote:

Quoting Justin French [EMAIL PROTECTED]:

On Tuesday, August 26, 2003, at 04:04  PM, Chinmoy Barua wrote:

Hello everybody,

I want to authenticate my user from web with PHP
script. The user's passwords are stored in System as
MD5 format (in /etc/shadow).
Can anybody help me?
See http://www.zend.com/zend/tut/authentication.php

--
Burhan
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] MD5 System Password check with PHP

2003-08-26 Thread Burhan
Quoting Justin French [EMAIL PROTECTED]:

 Burhan,
 
 Please try to quote the right person when replying to a thread -- your 
 messages was, I assume, intended for Chinmoy Barua, not me.
 
 It saves confusion, and keeps the thread more useful and easier to 
 follow.

My apologies Justin, I realized that when you pointed it out :(

-- 
Burhan
phplist[at]meidomus[dot]com
http://www.meidomus.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php