View Single Post
  #4 (permalink)  
Old Jan 2nd, 2008, 07:05
Rakuli's Avatar
Rakuli Rakuli is offline
SuperMember

SuperMember
Join Date: Sep 2007
Location: Australia
Age: 24
Posts: 956
Blog Entries: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Encrypted Password

You can never actually decrypt them, it is one way only.

When you are checking passwords, you are comparing hashes rather than passwords. You has the password first and the check it against the database value.

in mysql this would be

Code: Select all
SELECT username FROM table WHERE password = PASSWORD('monie')
Or in PHP

PHP: Select all



if (md5('monie') == $password)
    echo 
'Password is okay!'
Reply With Quote