Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

What is a Hash Function?

function hash
0
Posted

What is a Hash Function?

0

A hash function is an efficiently implementable function that converts data of any size into a number of fixed size. Typical output sizes in bits are 128 (used by MD4, MD5, RIPEMD), 160 (used by SHA-1, RIPEMD-160), 256 (SHA2-256), 512 (SHA2-512). There are several security requirements that exist for cryptographic hash functions (source: Wikipedia entry for pre-image attack): • One-way property or first pre-image resistance – difficulty of producing an input that corresponds to a given (random) output. In other words, given a hash value h, it is infeasible to find a message m such that hash(m) = h; • Second pre-image resistance – difficulty of finding a second input that produces the same output as given known input would produce. In other words, given a fixed message m1, it is infeasible to find a different message m2 such that hash(m2) = hash(m1); • Collision-free property – difficulty of producing a pair of different inputs that lead to the same output.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.