Message digests are created as a way to guarantee authenticity; if a message was sent, a digest or signature of this message provides an ability to check whether the message has been tampered with. Typically, the signature will therefore be transmitted differently than the original message.
Obviously, this requires the hashing function to adhere to some basic rules to be considered good, listed as follows:
- A signature has to be quick and easy to obtain regardless of message size
- The signature can only have a fixed length
- The function has to minimize collisions
The hash functions contained in this group are the most popular ones and are the objective of many security researchers: MD5, SHA-1/2/3, or Adler 32. Adler 32 is prominently used in the zlib library to ensure the file's integrity, but should not be used to authenticate messages, thanks to the limited output space of 32-bit. However, it is easy to implement and understand, which makes it great for the purposes...