|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
md5 & Encryption
A couple of questions...
1. Once I have md5 'd a password, how do I un-md5 it to show me what the original password was? 2. What is the best method of encryption to use when working with databases? |
|
#2
|
|||
|
|||
|
RE: md5 & Encryption
md5 is one way. Once you md5 a password, you can't get the original back....
As for how to encrpyt in a database? md5 isn't bad. If it's passwords you are dealing with and you are using MySQL, check the password function for MySQL.... |
|
#3
|
|||
|
|||
|
RE: md5 & Encryption
Quote:
As Matt indicated, md5() is a one-way hash... it generates a 32 character hash based on the input fed to it. As for the best, I don't know that there is a 'best' way, but I certainly prefer md5() for passwords. It makes it look like gibberish to anyone who can look into the db. I simply set up my programs to either allow a new password to be generated and emailed to the user if they forget their old one (good for internet apps), or have it such that an admin can manually generate a password for the user (good for intranet apps). Cheers, Keith. |
|
#4
|
|||
|
|||
|
RE: md5 & Encryption
i had the same problem not long back, and someone gave ma good suggestion that worked:
md5 the password, and then when people go to use the password, md5 it again and see if it matches the one in the database |
![]() |
| Viewing: Codewalkers Forums > PHP Related > PHP Coding > md5 & Encryption |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|