Outline Properties Hash Constructions Common Hash Functions
CPSC 467: Cryptography and Computer Security
Michael J. Fischer Lecture 15 October 28, 2015
CPSC 467, Lecture 15 1/52
CPSC 467: Cryptography and Computer Security Michael J. Fischer - - PowerPoint PPT Presentation
Outline Properties Hash Constructions Common Hash Functions CPSC 467: Cryptography and Computer Security Michael J. Fischer Lecture 15 October 28, 2015 CPSC 467, Lecture 15 1/52 Outline Properties Hash Constructions Common Hash
Outline Properties Hash Constructions Common Hash Functions
CPSC 467, Lecture 15 1/52
Outline Properties Hash Constructions Common Hash Functions
CPSC 467, Lecture 15 2/52
Outline Properties Hash Constructions Common Hash Functions
CPSC 467, Lecture 15 3/52
Outline Properties Hash Constructions Common Hash Functions
◮ One-way: Given y ∈ H, it is hard to find m ∈ M such that
◮ Weakly collision-free: Given m ∈ M, it is hard to find
◮ Strongly collision-free: It is hard to find colliding pairs (m, m′).
CPSC 467, Lecture 15 4/52
Outline Properties Hash Constructions Common Hash Functions Non-random
CPSC 467, Lecture 15 5/52
Outline Properties Hash Constructions Common Hash Functions Non-random
CPSC 467, Lecture 15 6/52
Outline Properties Hash Constructions Common Hash Functions Non-random
◮ H(m) is clearly collision-free since the only possible collisions
◮ Any colliding pair (m, m′) for H is also a colliding pair for h. ◮ Since h is collision-free, then so is H.
CPSC 467, Lecture 15 7/52
Outline Properties Hash Constructions Common Hash Functions Non-random
CPSC 467, Lecture 15 8/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 9/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
◮ Pick a random message m ∈ M. ◮ Try to find a colliding message m′. ◮ If we succeed, then output the colliding pair (m, m′). ◮ If not, try again with another randomly-chosen message.
CPSC 467, Lecture 15 10/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 11/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 12/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 13/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 14/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 15/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 16/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 17/52
Outline Properties Hash Constructions Common Hash Functions Relations among hash function properties
CPSC 467, Lecture 15 18/52
Outline Properties Hash Constructions Common Hash Functions
CPSC 467, Lecture 15 19/52
Outline Properties Hash Constructions Common Hash Functions Extension
CPSC 467, Lecture 15 20/52
Outline Properties Hash Constructions Common Hash Functions Extension
CPSC 467, Lecture 15 21/52
Outline Properties Hash Constructions Common Hash Functions Extension
CPSC 467, Lecture 15 22/52
Outline Properties Hash Constructions Common Hash Functions Extension
1m′ 2).
1) or h(m2) = h(m′ 2).
1)h(m′ 2).
1) and h(m2) = h(m′ 2).
1 or m2 = m′ 2 (or both).
CPSC 467, Lecture 15 23/52
Outline Properties Hash Constructions Common Hash Functions Chaining
◮ Divide m after appropriate padding into blocks m1m2 . . . mk,
◮ Compute a sequence of t-bit states:
CPSC 467, Lecture 15 24/52
Outline Properties Hash Constructions Common Hash Functions Chaining
CPSC 467, Lecture 15 25/52
Outline Properties Hash Constructions Common Hash Functions Chaining
◮ Let m = m1m2 . . . mk give state sequence s1, . . . , sk. ◮ Let m′ = m′ 1m′ 2 . . . m′ k′ give state sequence s′ 1, . . . , s′ k′.
k′.
k′−r.
k′−k+i.
CPSC 467, Lecture 15 26/52
Outline Properties Hash Constructions Common Hash Functions Chaining
j for all j = 1, . . . , k.
ℓ.
1) is a colliding pair for h.
ℓ−11m′ ℓ) is a colliding pair for h.
CPSC 467, Lecture 15 27/52
Outline Properties Hash Constructions Common Hash Functions Chaining
u.
u = h(s′ u−11m′ u),
u−11m′ u) is a colliding pair for h.
u−1 and m1 = m′ u, a possibility
CPSC 467, Lecture 15 28/52
Outline Properties Hash Constructions Common Hash Functions Chaining
u, but si−1 = s′ u−1.
u = h(s′ u−11m′ u),
u−11m′ u) is a colliding pair for h.
CPSC 467, Lecture 15 29/52
Outline Properties Hash Constructions Common Hash Functions Chaining
CPSC 467, Lecture 15 30/52
Outline Properties Hash Constructions Common Hash Functions
CPSC 467, Lecture 15 31/52
Outline Properties Hash Constructions Common Hash Functions
CPSC 467, Lecture 15 32/52
Outline Properties Hash Constructions Common Hash Functions SHA-2
CPSC 467, Lecture 15 33/52
Outline Properties Hash Constructions Common Hash Functions SHA-2
CPSC 467, Lecture 15 34/52
Outline Properties Hash Constructions Common Hash Functions SHA-2
CPSC 467, Lecture 15 35/52
Outline Properties Hash Constructions Common Hash Functions SHA-3
CPSC 467, Lecture 15 36/52
Outline Properties Hash Constructions Common Hash Functions SHA-3
CPSC 467, Lecture 15 37/52
Outline Properties Hash Constructions Common Hash Functions MD5
1How to Break MD5 and Other Hash Functions by Xiaoyun Wang and
CPSC 467, Lecture 15 38/52
Outline Properties Hash Constructions Common Hash Functions MD5
◮ The original message is padded to length a multiple of 512. ◮ The result m is split into a sequence of 512-bit blocks
◮ h is computed by chaining g on the first argument.
CPSC 467, Lecture 15 39/52
Outline Properties Hash Constructions Common Hash Functions MD5
CPSC 467, Lecture 15 40/52
Outline Properties Hash Constructions Common Hash Functions MD5
CPSC 467, Lecture 15 41/52
Outline Properties Hash Constructions Common Hash Functions MD5
1s′ 2s′ 3s′ 4.
1) · (s2 + s′ 2) · (s3 + s′ 3) · (s4 + s′ 4),
CPSC 467, Lecture 15 42/52
Outline Properties Hash Constructions Common Hash Functions MD5
CPSC 467, Lecture 15 43/52
Outline Properties Hash Constructions Common Hash Functions MD5
CPSC 467, Lecture 15 44/52
Birthday
CPSC 467, Lecture 15 45/52
Birthday
CPSC 467, Lecture 15 46/52
Birthday
2See Wikipedia, “Birthday paradox”. CPSC 467, Lecture 15 47/52
Birthday
CPSC 467, Lecture 15 48/52
Birthday
2
CPSC 467, Lecture 15 49/52
Birthday
2
CPSC 467, Lecture 15 50/52
Birthday
CPSC 467, Lecture 15 51/52
Birthday
CPSC 467, Lecture 15 52/52