Hashes and integrity: the mathematical seal of digital evidence
What a hash value is, why a single different bit changes it and how it is used to prove that digital evidence has not been altered.
A physical object is closed in a sealed bag. A file is not: it can be copied, moved, opened and modified without leaving visible marks. To prove that digital data have remained identical over time a different kind of seal is needed, and digital forensics finds it in mathematics: the hash value.
A hash function takes any amount of data as input — a message, a photo, a two-terabyte disk — and returns a fixed-length string. The same sequence of data always produces the same value; but changing a single bit is enough for the value to change completely.
What it is used for in practice
The hash value computed at acquisition is the identity card of the evidence. It is written in the record, quoted in the expert report and can be protected with a timestamp. Months or years later anyone can recompute it: if the result matches, the copy is the same; if it does not, something has changed.
- Integrity
- Shows that a file or forensic image has not been modified since acquisition.
- Identification
- Makes it possible to recognise a known file even if renamed or moved.
- Comparison
- Checks in seconds whether two copies are identical, without comparing them byte by byte.
- Confidentiality
- The value can be shared without revealing the content: the data cannot be recovered from the hash.
A hash does not say who created a file or when: it only attests that the content has stayed the same. That is why it works together with the chain of custody, which documents the history of the evidence, and the forensic image, which duplicates it without altering it.
The pages of this topic
Hashes and integrity: how it works
The properties that make a hash function suitable for forensic use and why MD5 and SHA-1 are no longer enough on their own.
Hashes and integrity: the step-by-step procedure
How hash values are computed, documented and verified during a forensic acquisition and in the later stages.
Hashes and integrity: the tools
From commands built into operating systems to forensic software: what is used to compute and verify hash values.
Hashes and integrity: pitfalls to avoid
Values computed too late, weak algorithms, the wrong files: the mistakes that take away the value of the hash seal.
Hashes and integrity: value in court
How the hash value meets the requirement to preserve original data and prevent their alteration, and its limits before a judge.
Hashes and integrity: a case study
A dispute over a video filed in a lawsuit: how hash values settle the question of whether the copies match.
Hashes and integrity: the checklist
The essential checks for using hash values correctly during an acquisition and in the later stages.
Hashes and integrity: frequently asked questions
Short answers to the most common doubts about hash values, algorithms and the integrity of digital evidence.