MD5 is the hash function everyone has heard of and nobody should use — for security. It’s a good story about how cryptographic tools age.
What MD5 does
Feed it any file or text; it outputs a fixed 32-character fingerprint:
"hello" → 5d41402abc4b2a76b9719d911017c592
Change one character and the fingerprint changes completely. That property — a compact, sensitive summary of content — was MD5’s job since 1992.
What broke
- 2004: researchers demonstrated collisions — two different inputs with the same MD5 hash. Once collisions are possible, an attacker can substitute one file for another with the same fingerprint.
- The practical attacks followed: forged SSL certificates, malware with legitimate-looking signatures, poisoned software downloads.
None of this means MD5 is “wrong” — it means MD5 is finished for integrity and security, where collision-resistance is the whole point.
What MD5 is still good for
- Checksums for non-adversarial use: verifying a download wasn’t corrupted in transit (not attacked — corrupted). Filesystems and package managers still use it this way.
- Quick identity checks: “is this the same file?” comparisons where nobody’s trying to fool you.
Generating hashes
The MD5 generator computes hashes in your browser. For anything that must resist tampering, use SHA-256 instead — the hash generator covers the modern family.
The rule of thumb: MD5 for detecting accidents, SHA-256 for resisting attacks. Same concept, different threat models — and confusing the two is how legacy systems get quietly exploited.