Kesh
Kesh

Reputation: 365

MD5 hash decryption when knowing part of input

Is it possible to decrypt an MD5 hash if you have part of the original text? Like:

Text     : hi how are you?
MD5 hash : 31a015d54f92382d2cee35eb2f0cc556

MD5 hashes can't be decrypted, but if I know part of the text like hi how are, does that help?

Upvotes: 0

Views: 4378

Answers (4)

user4157124
user4157124

Reputation: 2904

Is it possible to decrypt an MD5 hash if you have part of the original text?

Given an exhaustive key search (brute-force) attack is applied then theoretically the answer is yes, because knowing a digestive algorithm's partial input helps determine its complete original input by:

Theoretically, because cost (time) relates to key space and reduction does not necessarily result in manageable size. However, ability to dismiss collisions increases likeliness to discern actual input (which would not be possible otherwise).

Related.

Upvotes: 0

Luciano Barcaro
Luciano Barcaro

Reputation: 388

No, you can't, even with partial string.

With brute-force you can find a combination that generates the same MD5 hash but this combination may or may not be your original string (hash collision).

Upvotes: 1

Matt
Matt

Reputation: 1167

Assuming we aren't trying to use cracking techniques and we are talking about decrypting for use in a web app or something like that.

Hashing is not encryption meaning the password isn't stored in the hash and the MD5 hash is one-way. Meaning we can't get the password back from a hash, but we can tell that a hash could come from a password if we are given both. There is a very small chance another password could produce to the same hash which is called a collision. But this potential for collision is considered to be negligible.

However, MD5 has been cracked, it's no longer secure. Use something else. You can read up on how to crack it, if that is what you are tying to do.

https://security.stackexchange.com/questions/38141/if-hashing-is-one-way-why-can-we-decrypt-md5-hashes

http://www.zdnet.com/article/md5-password-scrambler-no-longer-safe/

Upvotes: 0

zchenah
zchenah

Reputation: 2108

If you know enough information about the unknown part, like "it is one common English word" or "it is a 6 digit number", then you can brute force all possibilities to get the correct one. "Enough" means the search space is smaller enough for brute force.

Upvotes: 1

Related Questions