Trusted answers to developer questions
Trusted Answers to Developer Questions

Related Tags

blockchain
cryptography

What are the different types of cryptographic hash functions?

Muhammad Zubair

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Cryptographic hash functions are one-way secure functions that map the user input of variable lengths into an encoded hash of a fixed size. They are computationally infeasible to break.

Types of cryptographic hash functions

There are two types of cryptographic hash functions:

  • Keyed cryptographic hash functions
  • Unkeyed cryptographic hash functions
Types and examples of cryptographic hash functions

Keyed cryptographic hash functions

We use keyed functions with a cryptographic key to compute a hash to authenticate the messages as they are transferred over a network.

Some examples of keyed cryptographic hash functions are given below.

Examples

  • MAC
  • HMAC
  • KMAC
  • MD6

Note: To learn more about keyed cryptographic hash functions, we can click here.

Unkeyed cryptographic hash functions

We use unkeyed functions alone, unlike the keyed functions. Unkeyed functions convert variable user input to a fixed hash value. The computed hash value detects changes in the data sent from the sender to the receiver.

Some examples of unkeyed cryptographic hash functions are given below.

Examples

  • SHA-1
  • SHA-256
  • SHA-512
  • MD4

Note: To learn more about unkeyed cryptographic hash functions, we can click here.

RELATED TAGS

blockchain
cryptography

CONTRIBUTOR

Muhammad Zubair
Copyright ©2022 Educative, Inc. All rights reserved

Grokking Modern System Design Interview for Engineers & Managers

Ace your System Design Interview and take your career to the next level. Learn to handle the design of applications like Netflix, Quora, Facebook, Uber, and many more in a 45-min interview. Learn the RESHADED framework for architecting web-scale applications by determining requirements, constraints, and assumptions before diving into a step-by-step design process.

Keep Exploring