I need to decode a password from md5 format to display the actual password in a account inof page. Is it possible?
You could find a string that gives the same hash, but you'll never know if it is the 'actual password'.
Let's take for example a simple hashing algorithm for:
n = h (mod m)
Our hash, h, is obtained by taking the original integer, n, under modulo m.
So given n=1,2,3 or 4
We get h=1,0,1 or 0 respectively.
Now given h=0 or h=1, you dont know which n is the original one that the algorithm was applied to.
If you were trying to break into a system it wouldnt matter, but if you have more altruistic reasons (e.g. to tell users who forgot their password what it was) it just wouldnt work, even if you found a way that made it computationally feasible to find strings that produce the same hash as the one you were given.
What that means is that mathematicians think the 128-bit encryption used in MD5 is un-crackable, but have not been able to come up with the proof yet. Of course they may be wrong; and you could win the Nobel prize by proving them wrong.
There is no Nobel prize in mathematics... but there is a Fields Medal :p
MD5 is an algorithm that generates 128-bit hashes with certain properties - it is not 128-bit encryption.
From what I've seen on the 'net, it has been proved that 2 different strings can produce the same MD5 hash.
That's obvious - the input is pretty much of unlimited length, while the output is fixed at a length of 128 bits.