Impossible plaintext cryptanalysis and probable-plaintext collision - - PowerPoint PPT Presentation

impossible plaintext cryptanalysis and probable plaintext
SMART_READER_LITE
LIVE PREVIEW

Impossible plaintext cryptanalysis and probable-plaintext collision - - PowerPoint PPT Presentation

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Impossible plaintext cryptanalysis and probable-plaintext collision attacks of 64-bit block cipher modes David McGrew mcgrew@cisco.com Fast


slide-1
SLIDE 1

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Impossible plaintext cryptanalysis and probable-plaintext collision attacks of 64-bit block cipher modes

David McGrew mcgrew@cisco.com Fast Software Encryption Workshop 2013 March 11-13, 2013

slide-2
SLIDE 2

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Outline

1

Background

2

Collision attack on CBC and CFB How it works Recovering plaintext Efficacy Rekeying

3

Impossible plaintext cryptanalysis of CTR Algorithms

4

Conclusions

slide-3
SLIDE 3

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Block ciphers w-bit block cipher with a κ-bit key E : {0, 1}w × {0, 1}κ → {0, 1}w, E−1 : {0, 1}w × {0, 1}κ → {0, 1}w such that E(E−1(x)) = E−1(E(x)) = x for all x ∈ {0, 1}.

slide-4
SLIDE 4

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Block ciphers w-bit block cipher with a κ-bit key E : {0, 1}w × {0, 1}κ → {0, 1}w, E−1 : {0, 1}w × {0, 1}κ → {0, 1}w such that E(E−1(x)) = E−1(E(x)) = x for all x ∈ {0, 1}. Examples MISTY w = 64 κ = 128 KASUMI w = 64 κ = 128 Triple-DES w = 64 κ = 168 GOST 28147-89 w = 64 κ = 256 AES w = 128 κ = 128, 192, 256

slide-5
SLIDE 5

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Modes of operation

slide-6
SLIDE 6

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Modes of operation Modes Pi =      E−1(Ci) ⊕ Ci−1 in CBC mode E(Ci−1) ⊕ Ci in CFB mode E(i) ⊕ Ci in CTR mode.

slide-7
SLIDE 7

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions How it works

Plaintext model

slide-8
SLIDE 8

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions How it works

Indicator Ii =

  • Ci

in CBC mode Ci−1 in CFB mode.

slide-9
SLIDE 9

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions How it works

Indicator collisions reveal information WhenIi = Ij for some i = j then Pi ⊕ Pj = ∆ij, where ∆ij =

  • Cj−1 ⊕ Ci−1

in CBC mode Cj ⊕ Ci in CFB mode.

slide-10
SLIDE 10

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Recovering plaintext

Exploiting collisions in theory Attacker’s knowledge about Pj → knowledge about Pi

slide-11
SLIDE 11

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Recovering plaintext

Exploiting collisions in theory Attacker’s knowledge about Pj → knowledge about Pi P[Pi = x|Pi ⊕ Pj = ∆] = P[Pj = x ⊕ ∆]P[Pi = x]

  • y P[Pj = y ⊕ ∆]P[Pi = y]
slide-12
SLIDE 12

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Recovering plaintext

Exploiting collisions in practice 0000101000000000 10.0.*.* Pi 1010110000010000 172.16.*.* 1100000010101000 192.168.*.*

slide-13
SLIDE 13

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Recovering plaintext

Exploiting collisions in practice 0000101000000000 10.0.*.* Pi 1010110000010000 172.16.*.* 1100000010101000 192.168.*.* Pj 1*******1******* ASCII

slide-14
SLIDE 14

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Recovering plaintext

Exploiting collisions in practice 0000101000000000 10.0.*.* Pi 1010110000010000 172.16.*.* 1100000010101000 192.168.*.* Pj 1*******1******* ASCII 1*******1******* Pi = 10.0.*.* ∆ij 0*******1******* Pi = 172.16.*.* 0*******0******* Pi = 192.168.*.*

slide-15
SLIDE 15

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Efficacy

Birthday bound for indicator collisions O(n) work and storage

slide-16
SLIDE 16

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Efficacy

Lemma Lemma The expected number of bits of unknown plaintext that are revealed in a collision attack with k blocks of known plaintext and u blocks of unknown plaintext is wku 2w ≤ n2 w 2w+2 , where n = k + u.

slide-17
SLIDE 17

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Efficacy

expected number of bits leaked due to collisions

slide-18
SLIDE 18

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Efficacy

expected number of bits leaked due to collisions

slide-19
SLIDE 19

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Efficacy

Network traffic with one-day rekeying Bits leaked per day w 1 Mbit/s 1 Gbit/s 1 Tbit/s 64 6.3 bits 6.3 × 106 bits 6.3 × 1012 bits 128 1.7 × 10−19 bits 1.7 × 10−13 bits 1.7 × 10−7 bits

slide-20
SLIDE 20

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Rekeying

Rekying to limit leakage Idea: limit number of blocks encrypted under each distinct key Corollary The expected number of bits of unknown plaintext that are leaked when a total t blocks are encrypted, changing keys every c blocks, is less than or equal to tcw2−w−2

slide-21
SLIDE 21

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Rekeying

Rekying to limit leakage Idea: limit number of blocks encrypted under each distinct key Corollary The expected number of bits of unknown plaintext that are leaked when a total t blocks are encrypted, changing keys every c blocks, is less than or equal to tcw2−w−2 Example: n = 220, t ≤ 2w−18−lg(w) = 240

slide-22
SLIDE 22

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext inferences Given Pi = E(i) ⊕ Ci

slide-23
SLIDE 23

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext inferences Given Pi = E(i) ⊕ Ci Pj = E(j) ⊕ Cj

slide-24
SLIDE 24

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext inferences Given Pi = E(i) ⊕ Ci Pj = E(j) ⊕ Cj E(i) = E(j) for i = j

slide-25
SLIDE 25

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext inferences Given Pi = E(i) ⊕ Ci Pj = E(j) ⊕ Cj E(i) = E(j) for i = j We know Pi = Pj ⊕ Ci ⊕ Cj

slide-26
SLIDE 26

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Extending across multiple known plaintexts

slide-27
SLIDE 27

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Extending across multiple known plaintexts Lemma part 1 For any ciphertext block Ci : i / ∈ K the corresponding plaintext block Pi / ∈ (E ⊕ Ci), where E = {E(j) : j ∈ K} = {Pj ⊕ Cj : j ∈ K}.

slide-28
SLIDE 28

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext model

slide-29
SLIDE 29

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext model

slide-30
SLIDE 30

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext model

slide-31
SLIDE 31

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Plaintext model

slide-32
SLIDE 32

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Extending across repeated target values Lemma part 2 An unknown repeated target value p corresponding to the set R satisfies φ / ∈ E ⊕ G, where G = {Cj : j ∈ R}.

slide-33
SLIDE 33

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Efficacy Estimate An impossible plaintext attack against an unknown repeated value with repetition r, a possible plaintext set of size #Φ = s, and k = #E known plaintext blocks succeeds when kr ≥ (ln(s) + 1)2w ≥ (w + 1)2w

slide-34
SLIDE 34

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Efficacy Estimate An impossible plaintext attack against an unknown repeated value with repetition r, a possible plaintext set of size #Φ = s, and k = #E known plaintext blocks succeeds when kr ≥ (ln(s) + 1)2w ≥ (w + 1)2w Heuristic #(E ⊕ G) = kr

slide-35
SLIDE 35

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Efficacy Estimate An impossible plaintext attack against an unknown repeated value with repetition r, a possible plaintext set of size #Φ = s, and k = #E known plaintext blocks succeeds when kr ≥ (ln(s) + 1)2w ≥ (w + 1)2w Heuristic #(E ⊕ G) = kr Collecting s coupons

slide-36
SLIDE 36

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Algorithms

Algorithms for finding p Sieving for ǫ ∈ E do for i ∈ R do remove Ci ⊕ ǫ from Φ end for end for return Φ

slide-37
SLIDE 37

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Algorithms

Algorithms for finding p Sieving for ǫ ∈ E do for i ∈ R do remove Ci ⊕ ǫ from Φ end for end for return Φ O(kr) operations, O(s) storage

slide-38
SLIDE 38

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Algorithms

Algorithms for finding p Searching for φ ∈ Φ do for i ∈ R do if Ci ⊕ φ ∈ E then remove φ from Φ end if end for end for return Φ

slide-39
SLIDE 39

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Algorithms

Algorithms for finding p Searching for φ ∈ Φ do for i ∈ R do if Ci ⊕ φ ∈ E then remove φ from Φ end if end for end for return Φ O(rs) operations, O(r + k) storage

slide-40
SLIDE 40

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Algorithms

Hybrid algorithm Observations sieving algorithm takes less work when k < s searching algorithm takes less work when k > s The first few passes of the sieving algorithm greatly reduce the size of the possible plaintext set.

slide-41
SLIDE 41

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions Algorithms

Hybrid algorithm Observations sieving algorithm takes less work when k < s searching algorithm takes less work when k > s The first few passes of the sieving algorithm greatly reduce the size of the possible plaintext set. Hybrid algorithm for k < s

1

Divide E into two distinct sets E = E1 ∪ E2, and

2

Run the sieving algorithm with E1 until #Φ has been reduced in size enough so that #Φ < k

3

Switch to sorting algorithm using E2

slide-42
SLIDE 42

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Conclusions CBC, CFB, CTR leak information about plaintext at birthday bound Can be exploited by practical attacks for w = 64

Security risk at high data rates

CTR leaks information more slowly in known-plaintext model CBC, CFB: Pi ⊕ Pj = δ CTR: Pi ⊕ Pj = δ

slide-43
SLIDE 43

Background Collision attack on CBC and CFB Impossible plaintext cryptanalysis of CTR Conclusions

Thank You

mcgrew@cisco.com