- File verification
File verification is the process of using an
algorithm for verifying the integrity or authenticity of acomputer file . This can be done by comparing two files bit-by-bit, but requires two copies of the same file, and may miss systematic corruptions which might occur to both files. A more popular approach is to also storechecksum s (hashes) of files for later comparison.Integrity verification
File integrity can be compromised, usually referred to as the file becoming corrupted. A file can become corrupted by a variety of ways: faulty
storage media , errors in transmission, write errors during copying or moving,software bug s, and so on.Hash-based verification ensures that a file has not been corrupted by comparing the file's hash value to a previously calculated value. If these values match, the file is presumed to be unmodified. Due to the nature of hash functions,
hash collision s may result infalse positive s, but the likelihood of collisions is often negligible with random corruption.Authenticity verification
It is often desirable to verify that a file hasn't been modified in transmission or storage by untrusted parties, for example, to include malicious code such as
virus es or backdoors. To verify the authenticity, a classical hash function is not enough since they are not designed to be collision resistant; it is computationally trivial for an attacker to cause deliberate hash collisions, meaning that a malicious change in the file is not detected with by a hash comparison. In cryptography, this attack is called thecollision attack .For this purpose,
cryptographic hash function s are employed often. As long as the hash sums cannot be tampered with — for example, if they are communicated over a secure channel — the files can be presumed to be intact. Alternatively,digital signature s can be employed to assure tamper-resistance.File formats
*
Simple file verification
*md5sum
*sha1sum See also
*
Checksum
*Comparison of file verification software
Wikimedia Foundation. 2010.