Differential Fault Analysis of Trivium Michal Hojsk 1 , 3 and - - PowerPoint PPT Presentation

differential fault analysis of trivium
SMART_READER_LITE
LIVE PREVIEW

Differential Fault Analysis of Trivium Michal Hojsk 1 , 3 and - - PowerPoint PPT Presentation

Differential Fault Analysis of Trivium Michal Hojsk 1 , 3 and Bohuslav Rudolf 2 , 3 1The Selmer Center, University of Bergen, Norway 2National Security Authority, Czech Republic 3Department of Algebra, Charles University in Prague, Czech


slide-1
SLIDE 1

Differential Fault Analysis of Trivium

Michal Hojsík 1, 3 and Bohuslav Rudolf 2, 3

1The Selmer Center, University of Bergen, Norway 2National Security Authority, Czech Republic 3Department of Algebra, Charles University in Prague, Czech Republic

Fast Software Encryption 2008 February 10-13, Lausanne

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 1 / 13

slide-2
SLIDE 2

Talk outline

Talk outline

Trivium description Differential fault analysis Differential fault analysis of Trivium Experimental results

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 2 / 13

slide-3
SLIDE 3

Trivium

Trivium

Hardware oriented additive synchronous stream cipher Designed by de Cannière and Preneel in 2005 for eSTREAM Project Very fast in hardware and software 80-bit secret key and 80-bit initialisation vector Consists of 3 non-linear shift registers 288 bit inner state

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 3 / 13

slide-4
SLIDE 4

Trivium Cipher description

Trivium Description

Inner state IS = (s1, . . . , s288) Keystream generation algorithm:

s1 s66 s69 s91 s92 s93

❢ ❵ ❢ ❄ ✻ ✲ ✲ ❢ ✲ q ❄ ✻ ❢ ✛ ✲ s94

s162 s171 s175 s176 s177

❢ ❵ ❢ ❄ ✻ ✲ ✲ ❢ ✲ q✲ ❄ ✻ ❢ ✛ ✲ s178

s243 s264 s286 s287 s288

❢ ❵ ❢ ❄ ✻ ✲ ✲ ❢ ✲ q ❄ ✻ ❢ ✛ ✲ ❢ ✲ zi ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 4 / 13

slide-5
SLIDE 5

Trivium Cipher description

Trivium Description

Secret key K = (K1, . . . , K80), initialisation vector IV = (IV1, . . . , IV80) Initialisation algorithm = 1152 loops of the keystream gen. alg. without output

K1 · · · K80 · · ·

❢ ❵ ❢ ❄ ✻ ✲ ✲ ❢ ✲ ❄ ✻ ❢ ✛ ✲ IV1

· · · IV80 · · ·

❢ ❵ ❢ ❄ ✻ ✲ ✲ ❢ ✲ ❄ ✻ ❢ ✛ ✲

· · · 1 1 1

❢ ❵ ❢ ❄ ✻ ✲ ✲ ❢ ✲ ❄ ✻ ❢ ✛ ✲

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 4 / 13

slide-6
SLIDE 6

Differential Fault Analysis General overview

Differential Fault Analysis - DFA

Type of active side-channel attack - adversary actively interferes with a cryptosystem First used in 1996 by Boneh et al. for RSA and by Biham and Shamir for DES Results on stream ciphers, e.g. Hoch, Shamir 2004 – Fault Analysis of LFSR based ciphers, Lili128, Sober-t32 Biham, Grandboulan 2005 – Impossible Fault Analysis of RC4

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 5 / 13

slide-7
SLIDE 7

Differential Fault Analysis Attack model

DFA Attack Model

General DFA attack model: Attacker is able to inject a fault into a cipher inner state or intermediate result Attacker has only partial control over their number, location, timing ... Attacker can reset the device to its original state and repeat fault injection Our assumptions: Attacker is able to:

  • btain first n consecutive bits of (proper) keystream {zi} produced out of a state ISt

inject exactly one fault (bit flip) into ISt at random position → faulty inner state IS′

t

  • btain first n consecutive bits of faulty keystream {z′

i } produced out of IS′ t

repeat the fault injection into the same inner state ISt m times Can be achieved in the Chosen ciphertext attack scenario

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 6 / 13

slide-8
SLIDE 8

Trivium DFA Fault Injection

Fault Injection - Trivium

Attack is based on the simplicity of the Trivium feedback functions Attack uses simple equation (x + 1) · y + x · y = y

s1 s40 s66 s69 s91 s92 s93

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ s94

s162 s171 s175 s176 s177

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q✲ ❄ ✻ ❡ ✛ ✲ s178

s243 s264 s286 s287 s288

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ ❡ ✲ zi ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 7 / 13

slide-9
SLIDE 9

Trivium DFA Fault Injection

Fault Injection - Trivium

Attack is based on the simplicity of the Trivium feedback functions Attack uses simple equation (x + 1) · y + x · y = y

·

+1

· · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲

· · · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q✲ ❄ ✻ ❡ ✛ ✲

· · · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ ❡ ✲ · ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 7 / 13

slide-10
SLIDE 10

Trivium DFA Fault Injection

Fault Injection - Trivium

Attack is based on the simplicity of the Trivium feedback functions Attack uses simple equation (x + 1) · y + x · y = y

·

+1

· · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ +1

· · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q✲ ❄ ✻ ❡ ✛ ✲

· · · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ ❡ ✲ +1 ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 7 / 13

slide-11
SLIDE 11

Trivium DFA Fault Injection

Fault Injection - Trivium

Attack is based on the simplicity of the Trivium feedback functions Attack uses simple equation (x + 1) · y + x · y = y +1

·

+1

· · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲

·

+1

· · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q✲ ❄ ✻ ❡ ✛ ✲

· · · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ ❡ ✲ · ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 7 / 13

slide-12
SLIDE 12

Trivium DFA Fault Injection

Fault Injection - Trivium

Attack is based on the simplicity of the Trivium feedback functions Attack uses simple equation (s40 + 1) · s41 + s40 · s41 = s41 · +1

·

· +1

· ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ s41

+1

· · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q✲ ❄ ✻ ❡ ✛ ✲

· · · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ ❡ ✲ · ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 7 / 13

slide-13
SLIDE 13

Trivium DFA Fault Injection

Fault Injection - Trivium

Attack is based on the simplicity of the Trivium feedback functions Attack uses simple equation s39 · (s40 + 1) + s39 · s40 = s39 · +1

·

·

·

+1

·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ s39

s41

+1

· · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q✲ ❄ ✻ ❡ ✛ ✲

· · · · · ·

❡ ❵ ❡ ❄ ✻ ✲ ✲ ❡ ✲ q ❄ ✻ ❡ ✛ ✲ ❡ ✲ · ❄ ✻

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 7 / 13

slide-14
SLIDE 14

Trivium DFA Attack Description

Attack Description I

Core of the attack - solve a system of equations in the inner state bits ISt = (s1, . . . , s288) Use equations given by the (proper) keystream {zi} Use differential fault analysis to obtain more equations Precomputation: for each fault position e, 1 ≤ e ≤ 288 express first n delta-keystream bits as expression is (s1, . . . , s288) store the equations in a table Fault position determination: distance between the output bits differs for each register compute the distances between nonzero bits of a keystream difference determine the fault position - table lookup

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 8 / 13

slide-15
SLIDE 15

Trivium DFA Attack Description

Attack Description III

Attack algorithm:

  • obtain the proper keystream generated from ISt
  • insert the keystream equations into the system

while solution not found

  • reset the cipher to the state ISt
  • insert a fault into ISt at random position
  • obtain the faulty keystream
  • determine the fault position
  • insert delta keystream equations into the system
  • try to solve the system

end while

  • clock Trivium backwards until initial state reached
  • read the secret key and IV

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 9 / 13

slide-16
SLIDE 16

Trivium DFA Experimental Results

Experimental Results

Attack: Number of fault injections needed, m, to obtain T inner state bits (avg. over 1000 exp.)

T 60 80 100 120 140 160 180 200 220 240 260 280 288 m 28 35 39 41 42 42 42 42 42 43 43 43 43

Number of obtained equations: The average number (among all fault positions) of equations obtained from a random fault:

number The average number of equations of degree d obtained from one fault.

  • f steps

d = 1 d = 2 d = 3 d = 4 d = 5 d = 6 d = 7 200 1.99 2.52 0.89 220 1.99 4.14 1.53 240 1.99 5.99 2.82 0.03 260 1.99 7.76 4.15 1.13 0.45 0.37 0.28 280 1.99 9.22 5.22 3.42 1.47 1.23 0.96 300 1.99 9.77 5.86 7.10 3.55 2.66 2.09

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 10 / 13

slide-17
SLIDE 17

New Results

New Results (January 2008)

New DFA attack on Trivium Same assumptions as in the described attack Attack uses another cipher representation Attacker needs approx. 12 fault injections to obtain the secret key and IV

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 11 / 13

slide-18
SLIDE 18

Conclusion

Conclusion

Differential fault analysis of Trivium described The first time DFA applied to non-linear feedback shift register stream cipher Attacker can obtain the secret key after approx. 43 (12) fault injections Attack works in chosen ciphertext attack scenario Described attacks have low complexity and are easy to implement

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 12 / 13

slide-19
SLIDE 19

Conclusion

Thank you for your attention!

Michal Hojsík and Bohuslav Rudolf () Differential Fault Analysis of Trivium Fast Software Encryption 2008 13 / 13