470,855 Members | 1,278 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,855 developers. It's quick & easy.

Encryption

Hello group,

to give access to some of my pages I use a loginscript. When people register
the password is encrypted with the md5 function: $passw=md5("$inv_passw");

Now I want to have the user to ask for his password when he lost it by mail.
So the encrypted password needs to be decrypted. I thought to use the next
command:
$uncrypted = decrypt_md5($assw);

but this gives a fault:
Fatal error: Call to undefined function: decrypt_md5()

Can somebody tell me what I do wrong.

Thnx in advance.

RotterdamStudents
Jul 17 '05 #1
3 1625
RotterdamStudents wrote:
Hello group,

to give access to some of my pages I use a loginscript. When people
register the password is encrypted with the md5 function:
$passw=md5("$inv_passw");

Now I want to have the user to ask for his password when he lost it
by mail. So the encrypted password needs to be decrypted. I thought
to use the next command:
$uncrypted = decrypt_md5($assw);

but this gives a fault:
Fatal error: Call to undefined function: decrypt_md5()

Can somebody tell me what I do wrong.


md5 -can't- be decrypted... It's a one-way hash function

--
MVH Jeppe Uhd - NX http://nx.dk
Webhosting for nÝrder og andet godtfolk
Jul 17 '05 #2
Jeppe Uhd wrote:
to give access to some of my pages I use a loginscript. When people
register the password is encrypted with the md5 function:
$passw=md5("$inv_passw");

Now I want to have the user to ask for his password when he lost it
by mail. So the encrypted password needs to be decrypted. I thought
to use the next command:
$uncrypted = decrypt_md5($assw);

but this gives a fault:
Fatal error: Call to undefined function: decrypt_md5()

Can somebody tell me what I do wrong.


md5 -can't- be decrypted... It's a one-way hash function


And there's no such function as decrypt_md5(), hence the error message :)

If you want to check a function go to www.php.net/function_name where
function_name is the name of the function you want more info on. If the
function exists you'll be taken directly to the manual page. If it doesn't
then you'll be given a list of functions with similar names.
Jul 17 '05 #3
RotterdamStudents wrote:
Hello group,

to give access to some of my pages I use a loginscript. When people
register the password is encrypted with the md5 function:
$passw=md5("$inv_passw");

Now I want to have the user to ask for his password when he lost it
by mail. So the encrypted password needs to be decrypted. I thought
to use the next command:
$uncrypted = decrypt_md5($assw);

but this gives a fault:
Fatal error: Call to undefined function: decrypt_md5()

Can somebody tell me what I do wrong.


Most of all, you're trying to decrypt.

Instead of this, when someone loses the password you should create a new one
and send it, and write that new one into database, encrypted.

Berislav

--
If the Internet is a Marx Brothers movie, and Web, e-mail, and IRC are
Groucho, Chico, and Harpo, then Usenet is Zeppo.
Jul 17 '05 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by Cliff | last post: by
2 posts views Thread by Sumit Gupta | last post: by
4 posts views Thread by pintu | last post: by
1 post views Thread by =?Utf-8?B?bWljcm9ob2Y=?= | last post: by
11 posts views Thread by John Williams | last post: by
22 posts views Thread by j1mb0jay | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.