locked
Reverse To String RRS feed

  • Question

  • User-1499457942 posted

    Hi

    How to reverse a Md5 hash algorithm to Original String in C# 

    Thanks

    Monday, January 28, 2019 11:45 AM

All replies

  • User-2054057000 posted

    There is no way to reverse Md5 hash algorithm to Original String in any way. Otherwise people can easily break passwords.

    Monday, January 28, 2019 11:50 AM
  • User753101303 posted

    Hi,

    This is not the purpose of a "hash". If you hash another value and get the same hash then you were provided with the same value. Still you can't reconstruct the original value from the hash.

    It is often used for passwords as it allows to check a user provided the same password without really storing a value that could allow to get the clear text password.

    If used in this context, ASP.NET provides built in stuff for handling that...

    Monday, January 28, 2019 11:58 AM
  • User-1716253493 posted

    If you want to check password in a textbox, hash the text then compare it with hashed password from db.

    If you forgot the password, use password reset

    Tuesday, January 29, 2019 12:44 AM
  • User-1174608757 posted

    Hi jagjitSingh,

    According to your description, it is impossible to reverse a Md5 hash algorithm. In fact, MD5 is not encryption (though it may be used as part of some encryption algorithms), you could think it as a  one way has function.Think about this, in spite of  original password is finite, but there are an infinite number of possible inputs to a given hash function.

    May be you could find some websites which could decode the hash , in fact since most passwords set by people is short so you  could guess at someone's password by Googling for the hash or using a Rainbow table.

    The whole point is that when user use MD5 hash to encrypt password, the hash code they get does not contain the original information which  means Once a piece of data has been run through a hash function, there is no going back.

    Here is the link ,I hope it could help you.

    https://stackoverflow.com/questions/1240852/is-it-possible-to-decrypt-md5-hashes

    Best Regards

    Wei Zhang

    Tuesday, January 29, 2019 2:34 AM