Custom Search
 


What is checksum and how to calculate and use checksum values to verify data and file integrity



Checksum is a calculated value that is used to determine the integrity of data. Checksum serves as a unique identifier for the data (a file, a text string, or a hexadecimal string). If the data changes then so does the checksum value. This makes it easy to verify the integrity of the data.

To test data integrity, the sender of the data calculates checksum value by taking the sum of the binary data transmitted. When receiving the data, the receiver can perform the same calculation on the data and compare it with the checksum value provided by the sender. If the two values match, the receiver has a high degree of confidence that the data was received correctly.

Checksum value is also called hash value. The data that is calculated can be a file, a text string, or a hexadecimal string.

The most commonly used checksum is MD5 (Message-Digest algorithm 5) hash. MD5 was designed by Professor Ronald L. Rivest in 1991 to replace an earlier hash function, MD4. MD5 checksum is a 128-bit hash value (32 characters).

Use checksum values

In practice, checksum values are mainly used in three situations.

First, checksum value can be used to check data integrity when data is sent through telecommunication networks such as Internet.

For example, serious software download sites often display MD5 checksum value for each file they offer for downloading. After download the file, you calculate the checksum value of the file you downloaded and compare with the checksum value provided by the download website. If they match, you are sure that the file is in good shape - not corrupted or modified. The checksum value becomes a fingerprint of the file.

Another example of using checksum is to calculate the hash value of a text string such as a password. MD5 hash value for the text 'test' (without quotes) is 098f6bcd4621d373cade4e832627b4f6. This is a 32-character GUID (Global Unique Identifier).

When storing a password in a database, it is always a good idea to store the password's hash such as MD5 checksum value. This way, the plain password is not exposed to anyone even though reversing MD5 to its original text string is possible for simple words by using dictionary attack.

Second, checksum value can be used to check data integrity of stored data to see if the data has been modified or changed in any way over time. Data can be modified in many ways. It may be infected by viruses, packet loss when transferring through networks, accidental or intentional human changes of data, or anything else.

For example, you may have a file that you created and stored on a network drive. How to make sure that the file is identical two months later when you want to use it again? You can calculate the file's checksum value when you first created it. When you need the file two months later, calculate its checksum again and compare with your previous checksum calculation. If they are the same, you can have high degree of confidence that the file has not been tampered with by anyone.

Third, checksum values can be used to verify data burned to CDROM, CD-R (Compact Disc-Recordable), OR DVD, DVD-R.

How to calculate checksum values

  1. Calculate checksum value for a file, a text string or hex string.

    There are some free software tools to help you calculate checksum value. HashCalc is a good one that not only calculates MD5 value, but also calculates other popular algorithms such as MD2, MD4, SHA1, SHA2 (SHA256, SHA384, SHA512), RIPEMD160, PANAMA, TIGER, ADLER32, CRC32, and the hash used in Peer-to-Peer eDonkey and eMule tools. HashCalc supports 3 input data formats: file, text string and hex string.

    HashCalc supports file drag-and-drop functionality. With this tool you can quickly compare music, audio, sound, video, film, game, image, icon, document and other files, verify CD and hard drive files, perform checking of your .mp3, .mpeg, .mpg, .avi, .vcd, .iso, .zip, .gif, .jpg, .doc and other downloads.

  2. Calculate checksum values for all files in a folder and its sub-folder(s).

    When you burn a CD or copy large amount of files, you want to verify the accuracy of all files. To do so, a checksum value needs to be calculated for each file. In this case, a checksum file can be created to store checksum values for all files. For an example of checksum file, see MD5 checksum file generated by freeware FileCheckMD5.

    Freeware FileCheckMD5 allows you to calculate checksum values and create the checksum file. FileCheckMD5 is a Windows GUI based small application that can recursively calculate MD5 checksum values for all files in a folder and its subfolder(s).

    To test data integrity by using FileCheckMD5, see FileCheckMD5 how-to page.




Copyright© GeeksEngine.com



Other Recent Articles from the Safe Computing category:

1.Choose Good Passwords That You Can't Remember
2.Protect files and folders with file container
3.A MD5 checksum file generated by freeware FileCheckMD5
4.How to check data integrity for copying files / folders and CD burning
5.What is index.dat file and how your internet privacy is affected
6.What is keylogger and the differences between software and hardware keylogger
7.Protect Your Computer On the Internet For Free with Six Simple but Essential Steps
8.Introduce Free Password Manager - KeePass
9.Introduce Free Password Manager - Password Safe
10.Do you manage your username and password wisely?

Copyright © 2017 GeeksEngine.com. All Rights Reserved.

This website is hosted by HostGator.

No portion may be reproduced without my written permission. Software and hardware names mentioned on this site are registered trademarks of their respective companies. Should any right be infringed, it is totally unintentional. Drop me an email and I will promptly and gladly rectify it.

 
Home | Feedback | Terms of Use | Privacy Policy