0

ร encodes into 0f93821e0fbc6d3736da7df2c73024aa

I was wondering if it's possible to decode the hash back into the unicode form. If so, how can I approach this or how can I perform this.

Any help is appreciated, thanks.

qtt qtt
  • 187
  • 3
  • 5
  • 19

3 Answers3

1

m5d is a hashing algorithm, that is by nature monodirectional.

You just can't "decode" it.

The only option you have is bruteforcing.

whites11
  • 12,008
  • 3
  • 36
  • 53
  • Is it possible to get a unicode output from bruteforcing? – qtt qtt Aug 21 '17 at 09:58
  • Bruteforcing means you test all possible combinations of input (including input with unicode chars) until you find the corresponding md5 hash. – whites11 Aug 21 '17 at 15:47
1

The whole point of a hash is to present a fixed-length output for arbitrary input with the property that the same input results in the same output. Cryptographic hash functions like MD5, or SHA-1 are even designed so they cannot be reversed easily. Thus, no, you cannot do that.

Also, just as a thought exercise that shows that in the general case it just cannot work: MD5 is 128 bits long, so how could you possibly recover input that's larger than that? There are an infinite number of strings turning into the same digest, so while you could find a string that has the same hash, you're not guaranteed to find the one you started with.

Joey
  • 344,408
  • 85
  • 689
  • 683
  • Okay, thanks for the info. @whites11 mentioned something about bruteforcing, I will give that a go. – qtt qtt Aug 21 '17 at 09:59
  • That's the part I alluded to in the last paragraph with finding a string with the same hash. In any case, since hash algorithms operate on byte sequences, to have any hope of getting the original string back you'd also need to know about which Unicode encoding has been used and whether normalization (and which) has been applied. In general, what you asked is fairly nonsensical since the answer is simply »No«. So I suspect your actual question and purpose here is slightly different. – Joey Aug 21 '17 at 10:02
0

Whites11 has mentioned brute-forcing, however take into account this is not 'Decoding' the hash. This is simply hashing common inputs and comparing the 2 hashes to see if they match, unless you have a set of common inputs that may actually match the hash its very unlikely you will get anywhere with it.

Hashes are intentionally mono-directional, I can't think of why you would need to either you may need to rethink the logic of whatever project you're doing.

To summarize, you can't decode a hash, this is intentional and that's why hashing algorithms exist. And brute-forcing is hashing common inputs to see if they match your hash. It's commonly used for password cracking etc. Done with common password data sets. So may not be useful in your case.

http://www.md5online.org is a good example of bruteforcing, it is a database of previously bruteforce/tested hashes and their unicode inputs. You can try hashing a basic word like "password" and throwing it in there, it should show the original unicode input if it's a known hash!

Here are 2 excellent informative videos that cover hashing algorithms and brute-forcing hashes: https://www.youtube.com/watch?v=b4b8ktEV4Bg https://www.youtube.com/watch?v=7U-RbOKanYs

  • @qttqtt No problem mate. If you look at my edit there are 2 really good videos on the topics of hashing algorithms and brute forcing hashes (guy uses a university's super computer for the brute-forcing which is cool). – Felipe Warrener-Iglesias Aug 21 '17 at 10:51