Mixture Differential Cryptanalysis: a New Approach to Distinguishers - - PowerPoint PPT Presentation

mixture differential cryptanalysis
SMART_READER_LITE
LIVE PREVIEW

Mixture Differential Cryptanalysis: a New Approach to Distinguishers - - PowerPoint PPT Presentation

Mixture Differential Cryptanalysis: a New Approach to Distinguishers and Attacks on round-reduced AES Lorenzo Grassi, IAIK, TU Graz (Austria) March, 2019 www.iaik.tugraz.at Motivation At Eurocrypt 2017, the first secret-key distinguisher for


slide-1
SLIDE 1

Mixture Differential Cryptanalysis:

a New Approach to Distinguishers and Attacks

  • n round-reduced AES

Lorenzo Grassi, IAIK, TU Graz (Austria) March, 2019

slide-2
SLIDE 2

www.iaik.tugraz.at

Motivation

At Eurocrypt 2017, the first secret-key distinguisher for 5-round AES - based on the multiple-of-8 property - has been presented. However, it seems rather hard to implement a key-recovery attack different than brute-force like using such a distinguisher: can this new observation lead to attacks on AES which are competitive w.r.t. previously known results?

1 / 25

slide-3
SLIDE 3

www.iaik.tugraz.at

Table of Contents

1 AES Design and the “Multiple-of-8” Property 2 Mixture Differential Cryptanalysis 3 New Key-Recovery Attacks for AES 4 Concluding Remarks

2 / 25

slide-4
SLIDE 4

www.iaik.tugraz.at

Part I AES Design and the “Multiple-of-8” Property

slide-5
SLIDE 5

www.iaik.tugraz.at

AES

High-level description of AES [DR02]: block cipher based on a design principle known as substitution-permutation network; block size of 128 bits = 16 bytes, organized in a 4 × 4 matrix; key size of 128/192/256 bits & 10/12/14 rounds:

Source-code of the Figure – by J´ er´ emy Jean – copied from https://www.iacr.org/authors/tikz/ 3 / 25

slide-6
SLIDE 6

www.iaik.tugraz.at

“Multiple-of-8” property for 5-round AES [GRR17b]

Assume 5-round AES without the final MixColumns operation. Consider a set of 232 chosen plaintexts with one active diagonal  

A C C C C A C C C C A C C C C A

  The number of different pairs of ciphertexts which are equal in

  • ne (fixed) anti-diagonal

 

? ? ? ? ? ? ? ? ? ? ? ?

  is a multiple of 8 with probability 1 independent of the secret key, of the details of S-Box and of MixColumns matrix.

4 / 25

slide-7
SLIDE 7

www.iaik.tugraz.at

Multiple-of-8 Property– Formal Theorem

Consider 232·|I| plaintexts with |I| active diagonals (namely, in an affine space DI ⊕ a) and the corresponding ciphertexts after 5 rounds, i.e. (pi, ci ≡ R5(pi)) for i = 0, ..., 232·|I| − 1 where pi ∈ DI ⊕ a. Theorem (Eurocrypt 2017) For a fixed J ⊆ {0, 1, 2, 3}, let n be the number of different pairs

  • f ciphertexts (ci, cj) for i = j such that ci ⊕ cj are equal in

4 − |J| anti-diagonals (namely, c1 ⊕ c2 ∈ MJ): n := |{(pi, ci), (pj, cj) | ∀pi, pj ∈ DI⊕a, pi < pj and ci⊕cj ∈ MJ}|. The number n is a multiple of 8 independent of the secret key, of the details of S-Box and of MixColumns matrix.

5 / 25

slide-8
SLIDE 8

www.iaik.tugraz.at

What about a Key-Recovery Attack?

What happens if we extend the previous distinguisher into a key-recovery attack? E.g. DI ⊕ a

R5(·)

− − − − →

  • prob. 1

multiple-of-8

R−1(·)

← − − − − − − −

key-guessing ciphertexts

Problem: we need to guess the entire final round-key in order to check the property “ number of pairs of ciphertexts (ci, cj) s.t.

  • (ci, cj)
  • i < j and R−1(ci) ⊕ R−1(cj) = MC−1 ×

  

? ? ? ? ? ? ? ? ? ? ? ?

  

  • is a multiple of 8”

6 / 25

slide-9
SLIDE 9

www.iaik.tugraz.at

What about a Key-Recovery Attack?

What happens if we extend the previous distinguisher into a key-recovery attack? E.g. DI ⊕ a

R5(·)

− − − − →

  • prob. 1

multiple-of-8

R−1(·)

← − − − − − − −

key-guessing ciphertexts

Problem: we need to guess the entire final round-key in order to check the property “ number of pairs of ciphertexts (ci, cj) s.t.

  • (ci, cj)
  • i < j and R−1(ci) ⊕ R−1(cj) = MC−1 ×

  

? ? ? ? ? ? ? ? ? ? ? ?

  

  • is a multiple of 8”

6 / 25

slide-10
SLIDE 10

www.iaik.tugraz.at

Part II Mixture Differential Cryptanalysis

slide-11
SLIDE 11

www.iaik.tugraz.at

From Multiple-of-8 to Mixture Diff. Cryptanalysis

Why does the “multiple-of-8” property hold? Given a pair of plaintexts (p1, p2) s.t. R5(p1) ⊕ R5(p2) ∈ M, then other pairs of texts (q1, q2) have the same property (R5(q1) ⊕ R5(q2) ∈ M), where the pairs (p1, p2) and (q1, q2) are not independent. Instead of limiting ourselves to count the number of collisions and check that it is a multiple of 8, the idea is to check the relationships between the variables that generate the pairs of plaintexts (p1, p2) and (q1, q2). Mixture Differential Cryptanalysis: a way to translate the “multiple-of-8” 5-round distinguisher into a simpler and more convenient one (though, on a smaller number of rounds).

7 / 25

slide-12
SLIDE 12

www.iaik.tugraz.at

From Multiple-of-8 to Mixture Diff. Cryptanalysis

Why does the “multiple-of-8” property hold? Given a pair of plaintexts (p1, p2) s.t. R5(p1) ⊕ R5(p2) ∈ M, then other pairs of texts (q1, q2) have the same property (R5(q1) ⊕ R5(q2) ∈ M), where the pairs (p1, p2) and (q1, q2) are not independent. Instead of limiting ourselves to count the number of collisions and check that it is a multiple of 8, the idea is to check the relationships between the variables that generate the pairs of plaintexts (p1, p2) and (q1, q2). Mixture Differential Cryptanalysis: a way to translate the “multiple-of-8” 5-round distinguisher into a simpler and more convenient one (though, on a smaller number of rounds).

7 / 25

slide-13
SLIDE 13

www.iaik.tugraz.at

Mixture Diff. Cryptanalysis – 1st Case (1/2)

Consider p1, p2 ∈ C0 ⊕ a: p1 = a ⊕     x1 y1 z1 w1     , p2 = a ⊕     x2 y2 z2 w2     where x1 = x2, y1 = y2, z1 = z2 and w1 = w2. For the following: p1 ≡ (x1, y1, z1, w1) and p2 ≡ (x2, y2, z2, w2).

8 / 25

slide-14
SLIDE 14

www.iaik.tugraz.at

Mixture Diff. Cryptanalysis – 1st Case (2/2)

Given p1, p2 ∈ C0 ⊕ a as before: p1 ≡ (x1, y1, z1, w1) and p2 ≡ (x2, y2, z2, w2) it follows that R4(p1) ⊕ R4(p2) ∈ MJ if and only if R4(ˆ p1) ⊕ R4(ˆ p2) ∈ MJ where

ˆ p1 ≡ (x2, y1, z1, w1), ˆ p2 ≡ (x1, y2, z2, w2); ˆ p1 ≡ (x1, y2, z1, w1), ˆ p2 ≡ (x2, y1, z2, w2); ˆ p1 ≡ (x1, y1, z2, w1), ˆ p2 ≡ (x2, y2, z1, w2); ˆ p1 ≡ (x1, y1, z1, w2), ˆ p2 ≡ (x2, y2, z2, w1); ˆ p1 ≡ (x1, y1, z2, w2), ˆ p2 ≡ (x2, y2, z1, w1); ˆ p1 ≡ (x1, y2, z1, w2), ˆ p2 ≡ (x2, y1, z2, w1); ˆ p1 ≡ (x1, y2, z2, w1), ˆ p2 ≡ (x2, y1, z1, w2).

9 / 25

slide-15
SLIDE 15

www.iaik.tugraz.at

Mixture Diff. Cryptanalysis – 2nd Case

Given p1, p2 ∈ C0 ⊕ a as before: p1 ≡ (x1, y1, z1, w) and p2 ≡ (x2, y2, z2, w) it follows that R4(p1) ⊕ R4(p2) ∈ MJ if and only if R4(ˆ p1) ⊕ R4(ˆ p2) ∈ MJ where

ˆ p1 ≡ (x1, y1, z2, Ω), ˆ p2 ≡ (x2, y2, z2, Ω); ˆ p1 ≡ (x2, y1, z1, Ω), ˆ p2 ≡ (x1, y2, z2, Ω); ˆ p1 ≡ (x1, y2, z1, Ω), ˆ p2 ≡ (x2, y1, z2, Ω); ˆ p1 ≡ (x1, y1, z2, Ω), ˆ p2 ≡ (x2, y2, z1, Ω);

where Ω can take any value in F28.

10 / 25

slide-16
SLIDE 16

www.iaik.tugraz.at

Mixture Diff. Cryptanalysis – 3rd Case

Given p1, p2 ∈ C0 ⊕ a as before: p1 ≡ (x1, y1, z, w) and p2 ≡ (x2, y2, z, w) it follows that R4(p1) ⊕ R4(p2) ∈ MJ if and only if R4(ˆ p1) ⊕ R4(ˆ p2) ∈ MJ where

ˆ p1 ≡ (x1, y1, Z, Ω), ˆ p2 ≡ (x2, y2, Z, Ω); ˆ p1 ≡ (x2, y1, Z, Ω), ˆ p2 ≡ (x1, y2, Z, Ω);

where Z and Ω can take any value in F28.

11 / 25

slide-17
SLIDE 17

www.iaik.tugraz.at

Reduction to 2 Rounds AES

Since Prob

  • R2(x) ⊕ R2(y) ∈ MJ
  • x ⊕ y ∈ DJ
  • = 1

we can focus only on the two initial rounds: CI ⊕ b

R2(·)

− − − → DJ ⊕ a′

R2(·)

− − − − →

  • prob. 1 MJ ⊕ b′

Consider p1, p2 ∈ CI ⊕ a. We are going to prove that R2(p1) ⊕ R2(p2) ∈ DJ if and only if R2(ˆ p1) ⊕ R2(ˆ p2) ∈ DJ, where ˆ p1, ˆ p2 ∈ CI ⊕ a are defined as before.

12 / 25

slide-18
SLIDE 18

www.iaik.tugraz.at

Reduction to 2 Rounds AES

Since Prob

  • R2(x) ⊕ R2(y) ∈ MJ
  • x ⊕ y ∈ DJ
  • = 1

we can focus only on the two initial rounds: CI ⊕ b

R2(·)

− − − → DJ ⊕ a′

R2(·)

− − − − →

  • prob. 1 MJ ⊕ b′

Consider p1, p2 ∈ CI ⊕ a. We are going to prove that R2(p1) ⊕ R2(p2) ∈ DJ if and only if R2(ˆ p1) ⊕ R2(ˆ p2) ∈ DJ, where ˆ p1, ˆ p2 ∈ CI ⊕ a are defined as before.

12 / 25

slide-19
SLIDE 19

www.iaik.tugraz.at

Idea of the Proof

Given p1, p2 and ˆ p1, ˆ p2 in C0 ⊕ a as before, if R2(p1) ⊕ R2(p2) = R2(ˆ p1) ⊕ R2(ˆ p2) then the previous result R2(p1) ⊕ R2(p2) ∈ DJ iff R2(ˆ p1) ⊕ R2(ˆ p2) ∈ DJ follows immediately!

13 / 25

slide-20
SLIDE 20

www.iaik.tugraz.at

Super-Box Notation (1/2)

Let super-SB(·) be defined as super-SB(·) = S-Box ◦ ARK ◦ MC ◦ S-Box(·). 2-round AES can be rewritten as R2(·) = ARK ◦ MC ◦ SR ◦ super-SB ◦ SR(·)

14 / 25

slide-21
SLIDE 21

www.iaik.tugraz.at

Super-Box Notation (2/2)

By simple computation, R2(p1) ⊕ R2(p2) = R2(ˆ p1) ⊕ R2(ˆ p2) is equivalent to super-SB(P1) ⊕ super-SB(P2) = super-SB(ˆ P1) ⊕ super-SB(ˆ P2), where Pi ≡ SR(pi), ˆ Pi ≡ SR(ˆ pi) ∈ SR(CI) ⊕ a′ ≡ IDI ⊕ a′ for i = 1, 2.

15 / 25

slide-22
SLIDE 22

www.iaik.tugraz.at

Sketch of the Proof (1/2)

Given P1 = SR(p1), P2 = SR(p2) ∈ ID0 ⊕ a′, note that P1 = a′⊕     x1 y1 z1 w1     , P2 = a′⊕     x2 y2 z2 w2    

16 / 25

slide-23
SLIDE 23

www.iaik.tugraz.at

Sketch of the Proof

Since each column depends on different and independent variables; the super-SB works independently on each column; the XOR-sum is commutative; then super-SB(P1)⊕super-SB(P2) = super-SB(ˆ P1)⊕super-SB(ˆ P2) for each ˆ P1 and ˆ P2 obtained by mixing/swapping the columns

  • f P1 and P2, e.g.

ˆ P1 = a′ ⊕     x2 y1 z1 w1     , ˆ P2 = a′ ⊕     x1 y2 z2 w2    

17 / 25

slide-24
SLIDE 24

www.iaik.tugraz.at

Mixture Diff. Distinguisher on 4-round AES

Consider p1 ≡ (x1, y1, z1, w1), p2 ≡ (x2, y2, z2, w2) ∈ C0 ⊕ a s.t. c1 ⊕ c2 ≡ R4(p1) ⊕ R4(p2) ∈ MJ, i.e. c1 and c2 are equal in 4 − J anti-diagonals. Given ˆ p1, ˆ p2 ∈ C0 ⊕ a obtained my mixing/swapping the generating variables of p1, p2, then: 4-round AES: the event R4(ˆ p1) ⊕ R4(ˆ p2) ∈ MJ occurs with

  • prob. 1;

Random Perm.: the event Π(ˆ p1) ⊕ Π(ˆ p2) ∈ MJ occurs with

  • prob. 2−32·(4−|J|);

independently of the secret-key.

18 / 25

slide-25
SLIDE 25

www.iaik.tugraz.at

Distinguishers on 4-round AES

In bold, our new distinguisher for 4-round AES: they are all independent of the secret key! Data (CP/CC) Complexity Property 4 CP + 4 ACC 4 XOR Yoyo [RBH17] 216.25 231.5 M Impossible Diff. [BK00] 217 223.1 M ≈ 216.75 E Mixture Diff. 232 232 XOR Integral [DLR97]

20 M ≈ 1-round Encryption

19 / 25

slide-26
SLIDE 26

www.iaik.tugraz.at

Part III New Key-Recovery Attacks for AES

slide-27
SLIDE 27

www.iaik.tugraz.at

Mixture Diff. Distinguisher + Key-Recovery Attack

Since

a ⊕     x y z w    

R(·)

− − → b ⊕ MC ×     S-Box(x ⊕ k0,0) S-Box(y ⊕ k1,1) S-Box(z ⊕ k2,2) S-Box(w ⊕ k3,3)     ,

the relations among the generating variables of R(p1), R(p2) and of R(ˆ p1), R(ˆ p2) depend on the key. Idea of the attack: D0 ⊕ a

R(·)

− − − − − − − →

key guessing C0 ⊕ b R4(·)

− − − − − − − →

distinguisher Mixture Diff. Property

where the mixture differential property holds only for the secret-key!

20 / 25

slide-28
SLIDE 28

www.iaik.tugraz.at

Mixture Diff. Distinguisher + Key-Recovery Attack

Since

a ⊕     x y z w    

R(·)

− − → b ⊕ MC ×     S-Box(x ⊕ k0,0) S-Box(y ⊕ k1,1) S-Box(z ⊕ k2,2) S-Box(w ⊕ k3,3)     ,

the relations among the generating variables of R(p1), R(p2) and of R(ˆ p1), R(ˆ p2) depend on the key. Idea of the attack: D0 ⊕ a

R(·)

− − − − − − − →

key guessing C0 ⊕ b R4(·)

− − − − − − − →

distinguisher Mixture Diff. Property

where the mixture differential property holds only for the secret-key!

20 / 25

slide-29
SLIDE 29

www.iaik.tugraz.at

Mixture Diff. Key-Recovery Attack (1/2)

Consider 232 chosen plaintexts with one active diagonal, that is pi ∈ D0 ⊕ a for i = 1, ..., 232. Find a pair of plaintexts (p, p′) s.t. the corresponding ciphertexts after 5-round (c = R5(p), c′ = R5(p′)) satisfy the property c ⊕ c′ = R5(p) ⊕ R5(p′) ∈ MJ for a certain J, i.e. c and c′ are equal in 4 − |J| anti-diagonal(s).

21 / 25

slide-30
SLIDE 30

www.iaik.tugraz.at

Mixture Diff. Key-Recovery Attack (2/2)

For each guessed value of (k0,0, k1,1, k2,2, k3,3): partially compute 1-round encryption of R(p), R(p′) w.r.t. the guessed-key; let q, q′ be two texts obtained by swapping the generating variables of R(p), R(p′); partially compute 1-round decryption of ˆ q ≡ R−1(q), ˆ q′ ≡ R−1(q′) w.r.t. the guessed-key; if R5(ˆ q) ⊕ R5(ˆ q′) / ∈ MJ, then the guessed key is wrong (where R5(·) is computed under the secret-key).

22 / 25

slide-31
SLIDE 31

www.iaik.tugraz.at

Key-Recovery Attacks on 5-round AES-128

Property Data (CP/CC) Cost (E) Memory MitM [Der13] 8 264 256

  • Imp. Polytopic [Tie16]

15 270 241 Partial Sum [Tun12] 28 238 small Integral (EE) [DR02] 211 245.7 small Mixture Diff.⋆ [BDK+18] 222.25 222.25 220

  • Imp. Differential [BK01]

231.5 233 (+ 238) 238 Integral (EB) [DR02] 233 237.7 232 Mixture Diff. 233.6 233.3 234

⋆ ≡ follow-up work

At Crypto 2018, Bar-On et al. [BDK+18] present the best (mixture-differential) attacks on 7-round AES-192 which use practical amounts of data and memory.

23 / 25

slide-32
SLIDE 32

www.iaik.tugraz.at

Key-Recovery Attacks on 5-round AES-128

Property Data (CP/CC) Cost (E) Memory MitM [Der13] 8 264 256

  • Imp. Polytopic [Tie16]

15 270 241 Partial Sum [Tun12] 28 238 small Integral (EE) [DR02] 211 245.7 small Mixture Diff.⋆ [BDK+18] 222.25 222.25 220

  • Imp. Differential [BK01]

231.5 233 (+ 238) 238 Integral (EB) [DR02] 233 237.7 232 Mixture Diff. 233.6 233.3 234

⋆ ≡ follow-up work

At Crypto 2018, Bar-On et al. [BDK+18] present the best (mixture-differential) attacks on 7-round AES-192 which use practical amounts of data and memory.

23 / 25

slide-33
SLIDE 33

www.iaik.tugraz.at

Part IV Concluding Remarks

slide-34
SLIDE 34

www.iaik.tugraz.at

Future Open Problems

Mixture Differential Cryptanalysis: a way to translate the (complex) “multiple-of-8” 5-round distinguisher into a simpler and more convenient one. Future Open Problems: apply Mixture Differential on Tweakable AES-like ciphers: how many rounds can we break in related-tweak mode? is it possible to extend Mixture Differential distinguisher on 5 (or even more) rounds of AES? E.g.:

what about Mixture Differential in boomerang-/yoyo-like attacks? what about an “Impossible Mixture Differential Cryptanalysis”? (see http://eprint.iacr.org/2017/832)

24 / 25

slide-35
SLIDE 35

www.iaik.tugraz.at

Just Keep an Open Mind!

“Multiple-of-8” property hard to exploit directly for “practical applications”... however in less than 2 years it leads to new competitive distinguisher/attacks on round-reduced AES (e.g. Mixture Diff. Cryptanalysis and corresponding attacks proposed at Crypto 2018); new direction of research (e.g. next talk: “A General Proof Framework for Recent AES Distinguishers” by Boura et al.) and new unpublished results. Do not limit ourselves to maximize the number of rounds that can be broken using known techniques: also look for new directions in cryptanalysis that do not reach their full potential yet.

25 / 25

slide-36
SLIDE 36

www.iaik.tugraz.at

Just Keep an Open Mind!

“Multiple-of-8” property hard to exploit directly for “practical applications”... however in less than 2 years it leads to new competitive distinguisher/attacks on round-reduced AES (e.g. Mixture Diff. Cryptanalysis and corresponding attacks proposed at Crypto 2018); new direction of research (e.g. next talk: “A General Proof Framework for Recent AES Distinguishers” by Boura et al.) and new unpublished results. Do not limit ourselves to maximize the number of rounds that can be broken using known techniques: also look for new directions in cryptanalysis that do not reach their full potential yet.

25 / 25

slide-37
SLIDE 37

www.iaik.tugraz.at

Just Keep an Open Mind!

“Multiple-of-8” property hard to exploit directly for “practical applications”... however in less than 2 years it leads to new competitive distinguisher/attacks on round-reduced AES (e.g. Mixture Diff. Cryptanalysis and corresponding attacks proposed at Crypto 2018); new direction of research (e.g. next talk: “A General Proof Framework for Recent AES Distinguishers” by Boura et al.) and new unpublished results. Do not limit ourselves to maximize the number of rounds that can be broken using known techniques: also look for new directions in cryptanalysis that do not reach their full potential yet.

25 / 25

slide-38
SLIDE 38

www.iaik.tugraz.at

Thanks for your attention! Questions? Comments?

slide-39
SLIDE 39

www.iaik.tugraz.at

References I

  • A. Bar-On, O. Dunkelman, N. Keller, E. Ronen and A.

Shamir, Improved Key Recovery Attacks on Reduced-Round AES with Practical Data and Memory Complexities CRYPTO 2018

  • E. Biham and N. Keller

Cryptanalysis of Reduced Variants of Rijndael Unpublished 2000, http://csrc.nist.gov/archive/ aes/round2/conf3/papers/35-ebiham.pdf

  • J. Daemen, L. Knudsen and V. Rijmen

The block cipher Square FSE 1997

slide-40
SLIDE 40

www.iaik.tugraz.at

References II

  • J. Daemen and V. Rijmen

The Design of Rijndael AES - The Advanced Encryption Standard P . Derbez Meet-in-the-middle attacks on AES PhD Thesis 2013

  • L. Grassi

Mixture Differential Cryptanalysis and Structural Truncated Differential Attacks on round-reduced AES ePrint 2017/832

slide-41
SLIDE 41

www.iaik.tugraz.at

References III

  • L. Grassi, C. Rechberger and S. Rønjom

Subspace Trail Cryptanalysis and its Applications to AES IACR Transactions on Symmetric Cryptology 2017

  • L. Grassi, C.Rechberger and S. Rønjom

A New Structural-Differential Property of 5-Round AES EUROCRYPT 2017

  • S. Rønjom, N.G. Bardeh and T. Helleseth

Yoyo Tricks with AES ASIACRYPT 2017

slide-42
SLIDE 42

www.iaik.tugraz.at

References IV

  • T. Tiessen

Polytopic Cryptanalysis EUROCRYPT 2016

  • M. Tunstall

Improved “Partial Sums” - based Square Attack on AES SECRYPT 2012