RE: md5() function

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

 



Thanks every body for your replies!!

It is clear to me that I can not reverse a hased string!!
Thanks!!!

Guirao

-----Original Message-----
From: Jason Gerfen [mailto:jason.gerfen@xxxxxxxxxxxx]
Sent: Lunes, 14 de Enero de 2008 02:04 p.m.
Cc: php-db@xxxxxxxxxxxxx
Subject: Re:  md5() function


Steven Cruz wrote:
> Hello;
> 
> I maybe wrong, but I believe it is one way. What you need to do is take
> your input and encrypt it and check if matches your current encrypted
> value. :)
> 
> peace and hugs.
> 
> Miguel Guirao wrote:
>> Hi!!
>>
>> I'm using the md5() function to encrypt a password and store it into a
>> database. Now I want to retrieve that MD5 password and convert it into
>> it's
>> human readable condition.
>> Is there a function opposite to md5()??
>>
>> Best Regards,
>>
>> M Guirao
>>
>>   
> 

If you want to do a comparison on the md5() hash you just created you
could always run your SQL query like:

SELECT * FROM `table` WHERE `password` = md5( $password ) LIMIT 1;

That will return a true or false value based on the md5() hash of the
$password var. But you cannot reverse the md5 hash to obtain the
original value unless you perform a crack on it using software available
software. I think what you are looking for is the base64_encode() and
base64_decode() functions which will perform a simple encoding of data.

-- 
Jason Gerfen

"I practice my religion
 while stepping on your
 toes..."
~The Ditty Bops

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

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


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux