| Computer Security lecture notes | Copyright © 2009 Mark Dermot Ryan The University of Birmingham Permission is granted to copy, distribute and/or modify this document (except where stated) under the terms of the GNU Free Documentation License, |
| (N-1)/N * (N-2)/N * . . . *
(N-n+1)/N |
= |
(1-(1/N)) * (1-(2/N)) * . .
. *
(1-((n-1)/N) |
| < |
e-1/N * e-2/N
* . . . * e-(n-1)/N |
|
| = |
e-n(n-1)/2N |
MD5 was designed in
1991 by Ron Rivest, and is widely used; for example, it is used by Red
Hat so that users
can
verify
that packages they download have not been tampered with (e.g., by
introducing trapdoors); PGP uses it for message signatures. MD5 takes
an
input of up to 264 bits (approx 109 Gigabytes),
and
produces a 128-bit hash (how many collisions do you think there are?).
Here is how it works.
These are still only collisions, i.e. breaks of the strongest property
in the list 1-4 above. One might argue that md5 is still secure for use
where only properties 1-3 are required. Many of the applications that
use cryptographic hashes, such as
password storage or document signing, are in principle only minimally
affected by a
collision attack. In the case of document signing, for example, an
attacker could not simply fake a signature from an existing document --
the attacker would have to fool the private key holder into signing a
preselected document. Reversing password hashing (e.g. to obtain a
password to try against a user's account elsewhere) does not require
collision resistance. Constructing a password that hashes to a given
value requires a preimage attack.
Here are two reasons for believing that collision-resistance is
important:
| SHA-1 |
SHA-256 |
SHA-384 |
SHA-512 |
|
| Message digest size |
160 |
256 |
384 |
512 |
| Message size |
<2^64 |
<2^64 |
<2^128 |
<2^128 |
| Block size |
512 |
512 |
1024 |
1024 |
| Word size |
32 |
32 |
64 |
64 |
| Number of steps |
80 |
80 |
80 |
80 |
So what now? Migration to
stronger hashes...