RE: Adding encryption to passwords

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You can try the MySQL built in functions. Ie encode(str, key)

insert into test (password) values (encode("mypass","some key"));

You can then use the decode() functions in your matching queries. 
You also need to consider security of your php code, as the key to decode
will be in the query strings. 

There are other built-in encryptions functions in MySQL you can explore.

-----Original Message-----
From: Thodoris [mailto:tgol@xxxxxxxxxx] 
Sent: 19 September 2008 10:25 AM
To: PHP General list
Subject:  Adding encryption to passwords

    Hi guys I have developed an intranet web interface with user access. 
I am storing the passwords into a mysql table as raw text (I know not so 
secure). So I am adding group access features and I am thinking to 
encrypt the passwords because this seems to grow as a project although 
it started as a simple web tool.

So  what do you think is  the best way to use crypt, mcrypt, hash or 
perhaps md5 and what are really the differences because I am not sure if 
I get it right.

-- 
Thodoris


-- 
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


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux