HAVAL160,5 Hash Tool
Other Hash Generator
MD2 MD4 MD5 SHA1 SHA224 SHA256 SHA384 SHA512/224 SHA512/256 SHA512 SHA3-224 SHA3-256 SHA3-384 SHA3-512 RIPEMD128 RIPEMD160 RIPEMD256 RIPEMD320 WHIRLPOOL TIGER128,3 TIGER160,3 TIGER192,3 TIGER128,4 TIGER160,4 TIGER192,4 SNEFRU SNEFRU256 GOST GOST-CRYPTO ADLER32 CRC32 CRC32B CRC32C FNV132 FNV1A32 FNV164 FNV1A64 JOAAT MURMUR3A MURMUR3C MURMUR3F XXH32 XXH64 XXH3 XXH128 HAVAL128,3 HAVAL160,3 HAVAL192,3 HAVAL224,3 HAVAL256,3 HAVAL128,4 HAVAL160,4 HAVAL192,4 HAVAL224,4 HAVAL256,4 HAVAL128,5 HAVAL160,5 HAVAL192,5 HAVAL224,5 HAVAL256,5The HAVAL-160/5 algorithm is a cryptographic hash function designed to generate fixed-length output from variable-length input data. It belongs to the HAVAL family, which is distinguished by its ability to produce hashes of 128, 160, 192, 224, or 256 bits and allows for 3, 4, or 5 rounds of processing. Specifically, HAVAL-160/5 produces a 160-bit digest using five rounds of transformation.
Input Processing
The algorithm begins by dividing the input message into blocks of 1024 bits. If the message length is not a multiple of 1024 bits, padding is applied according to a standardized scheme. The last 128 bits of the final block are reserved for representing the original message length in bits.
Initialization
HAVAL-160/5 initializes five 32-bit registers, often labeled as A, B, C, D, and E. These registers are loaded with predefined constants derived from mathematical sequences to ensure uniform distribution of hash values.
Round Functions
The core of HAVAL-160/5 consists of five distinct rounds. Each round applies a specific non-linear Boolean function to the five registers along with the message words. These functions include bitwise AND, OR, XOR, and conditional operations that combine message segments with register values. Each round uses a unique permutation of message word order and distinct constants to enhance diffusion and prevent structural weaknesses.
Compression
During each round, the registers are updated sequentially. The output of the last register in one step feeds into the next operation in the sequence. After completing five rounds for a single 1024-bit block, the intermediate hash values are combined with the previous block’s hash state using modular addition, producing an updated hash state. This iterative process continues until all blocks are processed.
Output Generation
After processing the final block, the algorithm concatenates the five 32-bit registers to produce a 160-bit hash value. This value serves as the unique fingerprint of the input data, providing strong avalanche properties where minor changes in the input result in significant differences in the output hash. The algorithm is optimized for software implementations and allows trade-offs between speed and security based on the number of rounds used.