Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to convert md5 string to normal text? [duplicate]

Tags:

php

md5

I have saved user passwords in MD5 form in my database, now I want to send password to users in plaintext, is there any way I can convert an MD5 string to plaintext?

like image 409
Ravinder Singh Avatar asked Jan 16 '12 10:01

Ravinder Singh


People also ask

Can we convert MD5 to string?

You cannot reverse the MD5 function, so your only option is to generate a new password and send that to the user (preferably over some secure channel).

Can you reverse md5sum?

Hash functions are not reversible in general. MD5 is a 128-bit hash, and so it maps any string, no matter how long, into 128 bits. Obviously if you run all strings of length, say, 129 bits, some of them have to hash to the same value.

Can MD5 be Unhashed?

It is pretty feasible if your passwords are hashed without a salt. Show activity on this post. MD5 is a hashing algorithm, you can not revert the hash value. You should add "change password feature", where the user gives another password, calculates the hash and store it as a new password.


1 Answers

Md5 is a hashing algorithm. There is no way to retrieve the original input from the hashed result.

If you want to add a "forgotten password?" feature, you could send your user an email with a temporary link to create a new password.

Note: Sending passwords in plain text is a BAD idea :)

like image 193
nulltoken Avatar answered Nov 15 '22 02:11

nulltoken