Hashes
In computing, a hash is the result of a function that maps input data of arbitrary size to a fixed-size output, commonly called a hash value or digest. A good hash function is deterministic, fast to compute, and designed so that small changes in the input produce large, unpredictable changes in the output (the avalanche effect). Hashes are widely used for data integrity, indexing, and content addressing.
Hash functions come in two main varieties: cryptographic hashes and non-cryptographic hashes. Cryptographic hashes, such as
Common applications include verifying data integrity (checksums), creating digital signatures and message authentication codes, and storing
Hash collisions—two distinct inputs producing the same hash—are possible by the pigeonhole principle. Security relies on