Home » Cryptography

Applications of Hash Function in Cryptography

This article is about the Applications of Hash Function. Hash Function is a very important topic of cryptography and it finds wide usage in current encryption and authentication techniques. In this article, we will study these applications of Hash Functions and then will have a brief explanation about each of them, its way of functioning and the ways by which it is implemented in various encryption techniques.
Submitted by Monika Sharma, on February 09, 2020

A Hash Function is a mathematical function that converts a numerical value into another compressed numeric value. The input value for the hash functions can be of arbitrary length, but the output text that it will produce will always be of fixed length.

Properties of Hash Functions

  1. Compressed output
  2. Fixed Length Output
  3. Pre-Image Resistance
  4. Second pre-Image Resistance
  5. Collision Resistance

Applications and of the hash functions

Password storage:

Due to the pre-Image resistance and collision resistance property, the hash functions are ideal to use for storing the passwords. Therefore, the values that are stored in the database are the user-Id in its original form and the hash value of the password. Therefore, whenever you enter the Id and password into a system, it searches for the user-Id, if available, it matches the hash values of the entered password and the password that is already there in the database. If both are the same, then access is granted.

This provides:

  1. Authentication:
    Whenever the user enters the id and password, the id is matched with the one with the present in the database, and the password entered is then and there converted into its hash value and is compared with that stored in the database.
  2. Provides high-level security:
    The hash function technique provides extreme level security, because even if the hacker or attacker is successful in breaking into the system’s database, all he gets is the user-Id and the hash value of the password, and getting the original password form this hash value is almost impossible.
applications of hash functions

Fig. The storage and Authentication methods for Id passwords.
Reference link: https://www.google.com/url?sa=i&rct=j&q=&esrc=s&source=images&cd=&ved=2ahUKEwi-vZHc4fXmAhWgIbcAHb5JBfgQjRx6BAgBEAQ&url=https%3A%2F%2Fwww.darkreading.com%2Fsafely-storing-user-passwords-hashing-vs-encrypting%2Fa%2Fd-id%2F1269374&psig=AOvVaw1p7DLjEAMSySYPZaaUqO_c&ust=1578633364016737

Data Integrity check:

To maintain the data integrity, the sender sends both the message and its hash value to the user. The Receiver then checks whether the hash value of the message is the same as the hash value sent by the sender. This ensures that no modification has been done in the data while being transmitted. This process of integrity checks can be seen in email systems, messaging applications, etc. However, as everything takes place in the back-end, the user cannot identify this process.

Digital Signature:

A signature is usually used to bind signatory to the message. The digital signature is thus a technique that binds a person or the entity to the digital data. This binding ensures that the person sending the data is solely responsible for being for it and this binding can be verified by the receiver and the third party. This digital signature is also stored using hash functions so that no one’s signature can be stolen and be misused.

Comments and Discussions

Ad: Are you a blogger? Join our Blogging forum.

Languages: » C » C++ » C++ STL » Java » Data Structure » C#.Net » Android » Kotlin » SQL
Web Technologies: » PHP » Python » JavaScript » CSS » Ajax » Node.js » Web programming/HTML
Solved programs: » C » C++ » DS » Java » C#
Aptitude que. & ans.: » C » C++ » Java » DBMS
Interview que. & ans.: » C » Embedded C » Java » SEO » HR
CS Subjects: » CS Basics » O.S. » Networks » DBMS » Embedded Systems » Cloud Computing
» Machine learning » CS Organizations » Linux » DOS
More: » Articles » Puzzles » News/Updates

© https://www.includehelp.com some rights reserved.