- Hashing algorithm is a cryptographic hash function. It is a mathematical algorithm that maps data of arbitrary size to a hash of a fixed size.
- Itís designed to be a one-way function, infeasible to invert. However, in time a lot of hashing algorithms are being compromised.
- This happened to md5, for example, a widely known hash function designed to be a cryptographic hash function,
which is now so easy to reverse, that we could only use it for verifying data against unintentional corruption.
Itís easy to figure out what the ideal cryptographic hash function should be like:
1. it should be fast to compute the hash value for any kind of data
2. it should be impossible to regenerate a message from its hash value (brute force attack as the only option)
3. it should avoid hash collisions, each message has its own hash.
4. every change to a message, even the smallest one, should change the hash value.
Even the smallest change (one letter) makes the whole hash different (SHA-1 example)