CSE 130 Lecture 04 - Modern Cryptography and Perfect Secrecy
CSE 130 Lecture 04 - Modern Cryptography and Perfect Secrecy
Introduction to Cryptography
Lecture 4 – Modern Cryptography and Perfect
Secrecy
Core principles of modern crypto
• Formal definitions
– Precise, mathematical model and definition of what security means
• Assumptions
– Most cryptographic proofs rely on currently unproven assumptions
about the algorithmic hardness of certain mathematical problems
– Clearly stated and unambiguous
• Proofs of security
– Move away from design-break-patch
If you don’t understand what you want to achieve, how can you possibly know
when (or if) you have achieved it?
• Provide modularity
– If underlying building block turns out not to satisfy the stated
assumption, instantiate scheme using a different component
• Threat model
– What (real-world) capabilities the attacker is assumed to have
key key
ciphertext
c
k k
m
c Enck(m) message/plaintext m := Deck(c)
decryption
encryption
Lec. Session 4.16
Threat models for encryption
• Ciphertext-only attack
– One ciphertext or many?
– Adversary observes a ciphertext and attempts to determine
information about the plaintext
• Known-plaintext attack
– Adversary learns plaintext/ciphertext pairs generated using some
key
– deduce information about plaintext of some other ciphertext
produced using the same key
• Chosen-plaintext attack
– Adversary obtains plaintext/ciphertext pairs for plaintexts of its
choice
• Chosen-ciphertext attack
– Adversary is obtains (some information about) decryption of
ciphertexts of its choice
Lec. Session 4.17
Goal of secure encryption?
• How would you define what it means for encryption scheme (Gen,
Enc, Dec) over message space M to be secure?
– Against a (single) ciphertext-only attack
• Pr[C = ‘rqh’] = ?
= Pr[C = ‘rqh’ | M = ‘one’] · Pr[M = ‘one’]
+ Pr[ C = ‘rqh’ | M = ‘ten’] · Pr[M = ‘ten’]
= 1/26 · ½ + 0 · ½ = 1/52
• Correctness:
Deck( Enck(m) ) = k (k m)
= (k k) m = m
n bits
key
n bits n bits
message ciphertext
• Pr[C = c]
= m’ Pr[C = c | M = m’] · Pr[M = m’]
= m’ Pr[K = m’ c | M = m’] · Pr[M = m’]
= m’ 2-n · Pr[M = m’]
= 2-n
• Pr[M = m | C = c] = ?
= Pr[C = c | M = m] · Pr[M = m]/Pr[C = c]
= Pr[K = m c | M = m] · Pr[M = m] / 2-n
= 2-n · Pr[M = m] / 2-n
= Pr[M = m]