teach-ict.com logo

THE education site for computer science and ICT

2. Hashing uses

Hashing is a one-way process to map data of arbitary size into a fixed length value or key

An important feature of an algorithm that creates hashes (called a hash function) is that, unlike encryption, hashing is intended to be a one-way process.

You cannot easily reconstruct the original data even if you know the hash function. What it does instead is seek to create a unique 'fingerprint' for the input string.

An important feature of a good hash function is that there should be a low chance of two different strings ending up with the same hash value.

These features make hashing useful for several things. For example,

 

Maintaining data integrity

If you are transferring data and are worried someone might modify or delete sections during transit, you can create a hash before sending it. Then both the message and the hash is sent.

Once the data reaches its destination, the same algorithm is used to create a hash of the received message. Then the received and calculated hashes are compared. If any of the data was corrupted, modified, or lost, the source and destination files will produce different hashes.

Other uses include:

  • Encrypting password and email addresses
  • Database indexing
  • Hard disk storage management
  • Fast searching
  • Digital authentication signatures

 

Challenge see if you can find out one extra fact on this topic that we haven't already told you

Click on this link: What is a hash function