6

Is there any way to decrypt the encrypted MD5 string, given the key?

Henry Ecker
  • 34,399
  • 18
  • 41
  • 57
ha22109
  • 8,036
  • 13
  • 44
  • 48
  • 8
    encrypted with what? md5 is hashing, not encrypting. – SilentGhost Oct 13 '09 at 18:25
  • MD5 hash is a one-way function. – Andrey Vlasovskikh Oct 13 '09 at 18:46
  • 2
    While the premise of the question is flawed (A hash is "a one way trip" i.e. it is `not a bijective function`, and also it doesn't involve a key, only an input message) the responses go beyond stating that "this is not what a hash is for" and explore ways of finding messages that satisfy one particular hash value, and ways of protecting against `dictionary/brute-force` attacks with the use of `salt`. Interesting ! – mjv Oct 13 '09 at 18:59
  • @mjv not being bijective is not the property that makes md5 a "cryptographic hash function". for instance f = x*x is not bijective but it is not "a one way trip" because if i said that f(x)=4 you would know that x would either be -2 or 2 that does not happen with cryptographic hashing functions. hope i was clear ;) – João Portela Oct 13 '09 at 22:21
  • 7
    Why downvote this question? Sure, he didn't understand what MD5 is in the first place, but the question is still valid. – ibz Dec 15 '09 at 02:44
  • 2
    I agree @ibz. Plus, hashing is encrypting too. The hash value is cryptographic and the correct term for this "hashing" is actually "cryptographic hashing". – cregox May 04 '10 at 22:12

5 Answers5

22

MD5 is a one-way hash. It cannot be decrypted. The closest thing to decrypting an MD5 hash would be to do a lookup against a pre-generated rainbow table. Also, I'm not sure what you mean by "I have the key". There is no "key" in an MD5 hash. Perhaps you are thinking of a salt? If your data has a salt value incorporated prior to hashing, the rainbow table approach probably won't be practical anyway.

Brian
  • 25,523
  • 18
  • 82
  • 173
Asaph
  • 159,146
  • 25
  • 197
  • 199
5

Try Google (see Using Google To Crack MD5 Passwords) or an online DB of MD5 hashes like md5(); or GDATA (the last one contains 1,133,766,035 unique entries).

Pascal Thivent
  • 562,542
  • 136
  • 1,062
  • 1,124
4

MD5 is not a encryption algorithm, it is a hashing algorithm. Read up on MD5 and Crytographic Hash Functions.

To create a MD5 hash of a string in Python you do as follows:

import hashlib
m = hashlib.md5()
m.update("String to Hash")
echo m.digest()
# '\xed\xa5\x8bA-nU\xa2\xee\xbb[_s\x130\xbd'
echo m.hexdigest() # its more common to show hashes as a hex string
# 'eda58b412d6e55a2eebb5b5f731330bd'
Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
MitMaro
  • 5,607
  • 6
  • 28
  • 52
4

Message-Digest algorithm 5 is a widely-used cryptographic hash function with a 128-bit hash value. Encryption has 2 way : encrypt - decript, hash has one way - there is no decryption possible. BUT with database hash IS POSSIBLE to solve this issue.

See this sites :

www.rednoize.com – 50,709,274 Hash in database

www.md5oogle.com – 6,353,625 Hash in database

www.hashmash.com – 1,611,191 Hash in database

www.gdataonline.com 1,155,613 Hash in database

www.md5decryption.com – 872,145 Hash in database

www.md5decrypter.com – 583,441 Hash in database

www.md5decrypter.co.uk – 41,568,541 Hash in database

www.macrosoftware.ro – 5,403 Hash in database

Paolo
  • 20,112
  • 21
  • 72
  • 113
2

MD5 is an asymmetric hash -- not an encryption mechanism. You can't "decrypt" an MD5. If you know the hashed contents are limited to a (short) set of possibilities, you can use a Rainbow Table to attempt to brute-force reverse the hash, but this will not work in the general case.

dcrosta
  • 26,009
  • 8
  • 71
  • 83