Hashing is a process where you transform a key or a series of characters into another, different value. And the value that comes out of the hashing process is called a hash value, hash code, hash, or digest. When you engage in hashing, you essentially map keys and values into a hash table. And you can do this by using a hash function. Most people use hashing to get easier access to elements, and the most popular use case of hashing is the implementation of hash tables.
- MD5. MD5 is a hashing function that encodes information into a 128-bit hash value, often referred to as a fingerprint. You can use it to verify data integrity, but keep in mind that it has higher chances of causing hash collisions compared to other hashing types.
- SHA-2. The NSA (National Security Agency) created SHA-2 so that it could create and send cryptic messages. SHA-2 has six hash functions, which include SHA-224, SHA-256, SHA-384, SHA-512, SHA-512/224, and SHA-512/256.
- CRC32. CRC stands for cyclic redundancy check. You can use it to detect unexpected or accidental changes in your data and to check your file’s integrity. Today, it is used mostly for zip files and FTP servers to verify integrity of the files.