The Additive Differential Probability of ARX V. Velichkov N. Mouha - - PowerPoint PPT Presentation

the additive differential probability of arx
SMART_READER_LITE
LIVE PREVIEW

The Additive Differential Probability of ARX V. Velichkov N. Mouha - - PowerPoint PPT Presentation

Introduction ARX S-functions adp ARX Experiments The Additive Differential Probability of ARX V. Velichkov N. Mouha C. De Cannire B. Preneel ESAT/COSIC, K.U.Leuven; IBBT FSE 2011, February 14-16, Lyngby, Denmark 1 / 47 Introduction


slide-1
SLIDE 1

Introduction ARX S-functions adpARX Experiments

The Additive Differential Probability of ARX

  • V. Velichkov
  • N. Mouha
  • C. De Cannière
  • B. Preneel

ESAT/COSIC, K.U.Leuven; IBBT

FSE 2011, February 14-16, Lyngby, Denmark

1 / 47

slide-2
SLIDE 2

Introduction ARX S-functions adpARX Experiments

Outline

Introduction ARX S-functions adpARX Experiments

2 / 47

slide-3
SLIDE 3

Introduction ARX S-functions adpARX Experiments

Outline

Introduction ARX S-functions adpARX Experiments

3 / 47

slide-4
SLIDE 4

Introduction ARX S-functions adpARX Experiments

Differential Cryptanalysis

p1 c1 a1 b1 p2 c2 a2 b2 ∆a ∆b ∆c ∆p P(∆p → ∆c) =?

4 / 47

slide-5
SLIDE 5

Introduction ARX S-functions adpARX Experiments

Addition, Rotation, XOR

Combining ⊞, ≪, ⊕ improves resistance to differential cryptanalysis a1 ARX b1

◮ Addition (⊞) : non-linearity ◮ Rotation (≪) : diffusion within a

single word

◮ XOR (⊕): diffusion between words

5 / 47

slide-6
SLIDE 6

Introduction ARX S-functions adpARX Experiments

Differential Properties of Addition, Rotation, XOR: Previous Work

P ⊞ ≪ ⊕ ARX ∆+ 1 adp≪ adp⊕ adpARX ∆⊕ xdp+ 1 1 xdpARX ⇔ xdp+

adp : additive differential probability xdp : xor differential probability

6 / 47

slide-7
SLIDE 7

Introduction ARX S-functions adpARX Experiments

Outline

Introduction ARX S-functions adpARX Experiments

7 / 47

slide-8
SLIDE 8

Introduction ARX S-functions adpARX Experiments

The ARX Operation

ARX(a, b, d, r) = ((a + b) ≪ r) ⊕ d = e a b d ≪ r e

8 / 47

slide-9
SLIDE 9

Introduction ARX S-functions adpARX Experiments

adpARX : the Additive Differential Probability of ARX

adpARX(∆c, ∆d

r

− → ∆e) |{(c1, d1) : e2 − e1 = ∆e}| |{(c1, d1)}| (a1, a1 + ∆a) (b1, b1 + ∆b) (d1, d1 + ∆d) ≪ r (c1, c1 + ∆c) (e1, e2) : ∆e

9 / 47

slide-10
SLIDE 10

Introduction ARX S-functions adpARX Experiments

Estimation of adpARX using adp≪ and adp⊕

adpARX(∆c, ∆d

r

− → ∆e) ≈

  • i

adp≪(∆c

r

− → ∆qi)·adp⊕(∆qi, ∆d → ∆e) ∆a ∆b ∆d ≪ r ∆c ∆qi ∆e adp≪ adp⊕

10/ 47

slide-11
SLIDE 11

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆e = 1

11/ 47

slide-12
SLIDE 12

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c = 8 ∆e = 1 1

12/ 47

slide-13
SLIDE 13

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c = 8 ∆q1 = 1 ∆e = 1 1 2−1

13/ 47

slide-14
SLIDE 14

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c = 8 ∆q1 = 1, ∆q2 = 15 ∆e = 1 1 2−1 2−1

14/ 47

slide-15
SLIDE 15

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c = 8 ∆q1 = 1, ∆q2 = 15 ∆e = 1 1 2−1 2−1 2−1.54 2−1.54

15/ 47

slide-16
SLIDE 16

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

  • adp≪ · adp⊕ = 2−1 · 2−1.54 + 2−1 · 2−1.54 = 2−1.54

= adpARX = 2−1

16/ 47

slide-17
SLIDE 17

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c = 8 ∆q = 1 (q1, q2) = (1, 2) ∆e = 1

17/ 47

slide-18
SLIDE 18

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c = 8 ∆q = 1 (q1, q2) = (1, 2) ∆e = 1

18/ 47

slide-19
SLIDE 19

Introduction ARX S-functions adpARX Experiments

4-bit Example: adpARX = adp≪ · adp⊕

∆a = 8 ∆b = 0 ∆d = 0 ≪ 1 ∆c′ = 9 ∆c = 8= ∆q = 1 (q1, q2) = (1, 2) ∆e = 1 ≫ 1

19/ 47

slide-20
SLIDE 20

Introduction ARX S-functions adpARX Experiments

ARX as a Single Operation

∆a ∆b ∆d ≪ r ∆c ∆q ∆e

20/ 47

slide-21
SLIDE 21

Introduction ARX S-functions adpARX Experiments

Outline

Introduction ARX S-functions adpARX Experiments

21/ 47

slide-22
SLIDE 22

Introduction ARX S-functions adpARX Experiments

S-function [Mouha et al.,SAC 2010]

Simple 4-bit example: a + b = c (c[i], S[i + 1]) = f(a[i], b[i], S[i]), 0 ≤ i < 4 . a[0] b[0] S[0] c[0] a[1] b[1] S[1] c[1] a[2] b[2] S[2] c[2] a[3] b[3] S[3] S[4] c[3]

22/ 47

slide-23
SLIDE 23

Introduction ARX S-functions adpARX Experiments

S-functions: General Case

An S-function accepts n-bit words a1, a2, . . . , ak and an n-digit input state S, and produces an n-bit output word b: (b[i], S[i + 1]) = f(a1[i], a2[i], . . . , ak[i], S[i]), 0 ≤ i < n .

f . . . a1[0] a2[0] ak[0] b[0] S[0] f . . . a1[1] a2[1] ak[1] b[1] S[1] f . . . a1[n − 1] a2[n − 1] ak[n − 1] b[n − 1] S[n − 1] S[2] S[n] . . .

23/ 47

slide-24
SLIDE 24

Introduction ARX S-functions adpARX Experiments

S-function for adp⊕

(∆e[i], S[i + 1]) = f(c1[i], d1[i], ∆c[i], ∆d[i], S[i]), 0 ≤ i < n ∆c ∆d ∆e                c2 ← c1 + ∆c , d2 ← d1 + ∆d , e1 ← c1 ⊕ d1 , e2 ← c2 ⊕ d2 , ∆e ← e2 − e1

24/ 47

slide-25
SLIDE 25

Introduction ARX S-functions adpARX Experiments

The State S

The state S[i + 1] at time i + 1 is composed of two carries and

  • ne borrow:

S[i + 1] ← (s1[i + 1], s2[i + 1], s3[i + 1]) , where s1[i + 1] ← (c1[i] + ∆c[i] + s1[i]) ≫ 1 , s2[i + 1] ← (d1[i] + ∆d[i] + s2[i]) ≫ 1 , s3[i + 1] ← (e2[i] − e1[i] + s3[i]) ≫ 1 . The initial state is S[0] = (0, 0, 0)

25/ 47

slide-26
SLIDE 26

Introduction ARX S-functions adpARX Experiments

All States

S[i] has fixed size of 3 bits. There are 8 states in total:

S[i] 1 2 3 4 5 6 7 s1[i], s2[i], s3[i] 0,0,-1 1,0,-1 0,1,-1 1,1,-1 0,0,0 1,0,0 0,1,0 1,1,0 ◮ One adjacency matrix describes

◮ all transitions S[i] → S[i + 1] for fixed (∆c[i], ∆d[i], ∆e[i])

◮ Eight adjacency matrices in total

◮ one for each 3-tuple (∆c[i], ∆d[i], ∆e[i]) ◮ computed using the S-function for adp⊕ 26/ 47

slide-27
SLIDE 27

Introduction ARX S-functions adpARX Experiments

The Adjacency Matrices

(∆c[i], ∆d[i], ∆e[i]) = (0, 1, 1) S[i] 1 2 3 4 5 6 7 S[i + 1] 1 2 3 4 5 6 7             1 1 1 1 4 1 1 1 1 1 1 1 1             A011

Interpretation: There are 4 pairs (c1[i], d1[i]) for which (∆c[i], ∆d[i] → ∆e[i]), and S[i] = 2 → S[i + 1] = 2

27/ 47

slide-28
SLIDE 28

Introduction ARX S-functions adpARX Experiments

Example: adp⊕(∆c, ∆d → ∆e)

LSB MSB

0 0 0 1 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

28/ 47

slide-29
SLIDE 29

Introduction ARX S-functions adpARX Experiments

Example: adp⊕(∆c, ∆d → ∆e)

LSB MSB

0 0 0 1 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A101

2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

← S[0] = (0, 0, 0)

29/ 47

slide-30
SLIDE 30

Introduction ARX S-functions adpARX Experiments

Example: adp⊕(∆c, ∆d → ∆e)

LSB MSB

0 0 0 1 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A000A101

2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

← S[0] = (0, 0, 0)

30/ 47

slide-31
SLIDE 31

Introduction ARX S-functions adpARX Experiments

Example: adp⊕(∆c, ∆d → ∆e)

LSB MSB

0 0 0 1 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A000A000A101

2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

← S[0] = (0, 0, 0)

31/ 47

slide-32
SLIDE 32

Introduction ARX S-functions adpARX Experiments

Example: adp⊕(∆c, ∆d → ∆e)

LSB MSB

0 0 0 1 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

2−1.54 = 1

4

4

2 6 6 6 6 6 6 6 6 6 4 1 1 1 1 1 1 1 1 3 7 7 7 7 7 7 7 7 7 5

T

A000A000A000A101

2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

← S[0] = (0, 0, 0)

32/ 47

slide-33
SLIDE 33

Introduction ARX S-functions adpARX Experiments

Outline

Introduction ARX S-functions adpARX Experiments

33/ 47

slide-34
SLIDE 34

Introduction ARX S-functions adpARX Experiments

ARX : Circumventing the Intermediate Values

a1[i] b1[i] d1[i] ≪ r c1[i] q1[i]= c1[i − r] e1[i]

34/ 47

slide-35
SLIDE 35

Introduction ARX S-functions adpARX Experiments

ARX : Circumventing the Intermediate Values

a1[i] b1[i] d1[i + r] ≪ r c1[i] q1[i + r]= c1[i] e1[i + r]

35/ 47

slide-36
SLIDE 36

Introduction ARX S-functions adpARX Experiments

ARX : Circumventing the Intermediate Values

a1[i] b1[i] d1[i + r] ≪ r c1[i] q1[i + r]= c1[i] e1[i + r]

36/ 47

slide-37
SLIDE 37

Introduction ARX S-functions adpARX Experiments

S-function for adpARX

(∆e[i + r], S[i + 1]) = f(c1[i], d1[i + r], ∆c[i],∆d[i + r], S[i]), 0 ≤ i < n ∆a[i] ∆b[i] ∆d[i + r] ≪ r ∆c[i] ∆e[i + r]

37/ 47

slide-38
SLIDE 38

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

38/ 47

slide-39
SLIDE 39

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

S[0] = (0, 0, −1) S[0] = (0, 1, −1) S[0] = (0, 0, 0) S[0] = (0, 1, 0)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

39/ 47

slide-40
SLIDE 40

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

S[0] = (0, 0, −1) S[0] = (0, 1, −1) S[0] = (0, 0, 0) S[0] = (0, 1, 0)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

40/ 47

slide-41
SLIDE 41

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

S[0] = (0, 0, −1) S[0] = (0, 1, −1) S[0] = (0, 0, 0) S[0] = (0, 1, 0)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

41/ 47

slide-42
SLIDE 42

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

S[0] = (0, 0, −1) S[0] = (0, 1, −1) S[0] = (0, 0, 0) S[0] = (0, 1, 0)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

42/ 47

slide-43
SLIDE 43

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

S[0] = (0, 0, −1) S[0] = (0, 1, −1) S[0] = (0, 0, 0) S[0] = (0, 1, 0)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5

43/ 47

slide-44
SLIDE 44

Introduction ARX S-functions adpARX Experiments

Example: adpARX(∆c, ∆d

r

− → ∆e)

S[0] = (0, 0, −1) S[0] = (0, 1, −1) S[0] = (0, 0, 0) S[0] = (0, 1, 0)

LSB MSB

1 0 0 0 ∆c 0 0 0 0 ∆d 0 0 0 1 ∆e

2 6 6 6 6 6 6 6 6 6 4 1 1 3 7 7 7 7 7 7 7 7 7 5

T

A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 2 6 6 6 6 6 6 6 6 6 4 1 1 3 7 7 7 7 7 7 7 7 7 5

T

A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 + 2 6 6 6 6 6 6 6 6 6 4 1 1 3 7 7 7 7 7 7 7 7 7 5

T

A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 + 2−1 = 2 6 6 6 6 6 6 6 6 6 4 1 1 3 7 7 7 7 7 7 7 7 7 5

T

A5RA0A0A0 2 6 6 6 6 6 6 6 6 6 4 1 3 7 7 7 7 7 7 7 7 7 5 +

44/ 47

slide-45
SLIDE 45

Introduction ARX S-functions adpARX Experiments

Outline

Introduction ARX S-functions adpARX Experiments

45/ 47

slide-46
SLIDE 46

Introduction ARX S-functions adpARX Experiments

Experiments on 32-bit Additive Differences

# ∆c ∆d ∆e r Pexper PARX Protxor 1 0x80000100 0x00000000 0x0007fc00 11 −2.58 −2.58 −4.17 2 0x40000008 0x00000000 0x000001d0 6 −4.58 −4.58 −5.59 3 0x80000008 0x04000000 0xfc000f00 9 −4.16 −4.16 −5.70 4 0x40010001 0x04000000 0xd3ffc000 30 −5.90 −5.91 −6.60 5 0xa2005800 0x00400000 0xf4000b00 29 −7.53 −7.54 −8.57 6 0x45003700 0x00000000 0xc8ffbb00 16 −8.77 −8.76 −9.37 7 0x4007800d 0x03800300 0x01e803f0 21 −11.1 −11.1 −11.8 8 0xbf006400 0x00900050 0xf37ff9f0 28 −11.8 −11.8 −12.8

Pexper was computed over 222 random inputs

46/ 47

slide-47
SLIDE 47

Introduction ARX S-functions adpARX Experiments

Conclusions

◮ Proposed an algorithm for the exact computation of

adpARX

◮ Allows for more accurate computation of the

probabilities of characteristics

◮ Improving accuracy of characteristics may eventually lead

to attack

◮ Can be easily modified to handle other variations of ARX

e.g. AXR, RXA, XRA, etc.

47/ 47

slide-48
SLIDE 48

Introduction ARX S-functions adpARX Experiments

Conclusions

◮ Proposed an algorithm for the exact computation of

adpARX

◮ Allows for more accurate computation of the

probabilities of characteristics

◮ Improving accuracy of characteristics may eventually lead

to attack

◮ Can be easily modified to handle other variations of ARX

e.g. AXR, RXA, XRA, etc.

Thank you for your attention! Questions?

47/ 47