99
Significantly Improved Multi- bit Differentials for Reduced Round Salsa and ChaCha Arka Rai Choudhuri Johns Hopkins University USA Subhamoy Maitra Indian Statistical Institute India FSE 2017, Tokyo

Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

  • Upload
    others

  • View
    4

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Significantly Improved Multi-bit Differentials for Reduced

Round Salsa and ChaCha

Arka Rai Choudhuri

Johns Hopkins University

USA

Subhamoy Maitra

Indian Statistical Institute

India

FSE 2017, Tokyo

Page 2: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa and ChaCha

ARX based stream ciphers.

Designed by Dan Bernstein.

Page 3: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa and ChaCha

ARX based stream ciphers.

Designed by Dan Bernstein.

Salsa accepted into the eStream software portfolio (2007).

Page 4: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa and ChaCha

ARX based stream ciphers.

Designed by Dan Bernstein.

Salsa accepted into the eStream software portfolio (2007).

ChaCha designed to address some concerns about Salsa (2008).

Page 5: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Motivation

Page 6: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Motivation

Standardization process for inclusion of cipher suite based on ChaCha20-Poly1305 AEAD in TLS1.3 is almost complete.

Page 7: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Motivation

Standardization process for inclusion of cipher suite based on ChaCha20-Poly1305 AEAD in TLS1.3 is almost complete.

Existing cryptanalysis treats ciphers as black-boxes.

Page 8: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Motivation

Standardization process for inclusion of cipher suite based on ChaCha20-Poly1305 AEAD in TLS1.3 is almost complete.

Existing cryptanalysis treats ciphers as black-boxes.

Brute force search for multiple components in cryptanalysis.

Page 9: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Structure

Page 10: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Structure

https://en.wikipedia.org/wiki/File:Salsa_round_function.svg

Page 11: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Structure

Easy to implement.

https://en.wikipedia.org/wiki/File:Salsa_round_function.svg

Page 12: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Structure

Easy to implement.

Fast on PCs.https://en.wikipedia.org/wiki/File:Salsa_round_function.svg

Page 13: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Structure

Easy to implement.

Fast on PCs.

No security guarantees.

https://en.wikipedia.org/wiki/File:Salsa_round_function.svg

Page 14: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Non Randomness

Page 15: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

Page 16: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

Page 17: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

Page 18: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

Salsar

Salsar

Page 19: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

Salsar

Salsar

Page 20: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

Salsar

Salsar

Page 21: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

Salsar

Salsar

Page 22: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

Salsar

Salsar

Page 23: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

Salsar

Salsar

Page 24: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Attack idea (for R rounds) [Aumasson et al. 08]

r rounds

Δ

Page 25: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Attack idea (for R rounds) [Aumasson et al. 08]

r rounds

𝜀

Δ

Page 26: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Attack idea (for R rounds) [Aumasson et al. 08]

r rounds

𝜀

Δ

Page 27: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Attack idea (for R rounds) [Aumasson et al. 08]

r rounds

𝜀

Δ

significant key bits

non-significant key bits

Page 28: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Attack idea (for R rounds) [Aumasson et al. 08]

r rounds R-r rounds

𝜀

Δ

significant key bits

non-significant key bits

Page 29: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Attack idea (for R rounds) [Aumasson et al. 08]

r rounds R-r rounds

𝜀

Δ

significant key bits

non-significant key bits

Complexity of attack increases with increase in number of significant bits.

Page 30: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds

Page 31: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

Page 32: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

3 rounds

ChaCha

Page 33: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

4 rounds3 rounds

ChaCha

Page 34: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function

Page 35: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function 𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

Page 36: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function 𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

Page 37: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function 𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

abcd

Page 38: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function 𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

abcd

abc

d

Page 39: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function 𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

abcd

ab

cda

bc

d

Page 40: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa update function 𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

abcd

ab

cda

bc

d bcd

a

Page 41: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Differential-Linear Biases

Page 42: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

r rounds

r rounds

Page 43: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

r rounds

r rounds

r’ rounds

Page 44: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

r rounds

r rounds

r’ rounds

Page 45: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

∆(0) =

00?

0 0 00 ? ?? 0 0

0 0 0 0

𝑐0𝑘3𝑡′0

𝑘0 𝑘1 𝑘2𝑐1 𝑣′0 𝑣′1𝑡′1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

𝑐0𝑘3𝑡0

𝑘0 𝑘1 𝑘2𝑐1 𝑣0 𝑣1𝑡1 𝑐2 𝑥11

𝑘5 𝑘6 𝑘7 𝑐3

∆(𝑟) =

???

? ? ?? ? ?? ? ?

? ? ? ?

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

𝑥′0𝑥′4𝑥′8

𝑥′1 𝑥′2 𝑥′3𝑥′5 𝑥′6 𝑥′7𝑥′9 𝑥′10 𝑥′11

𝑥′12 𝑥′13 𝑥′14 𝑥′15

𝑥0𝑥4𝑥8

𝑥1 𝑥2 𝑥3𝑥5 𝑥6 𝑥7𝑥9 𝑥10 𝑥11

𝑥12 𝑥13 𝑥14 𝑥15

r rounds

r rounds

r’ rounds

Given 𝜀𝑑 and 𝜀𝐿 , we can find the differential-linear bias for r+r’rounds.

Page 46: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 = 1

Let’s look at the Salsa update function again

Page 47: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 = 1

Let’s look at the Salsa update function again

Page 48: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Let’s look at the Salsa update function again

Page 49: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Get rid of the carry.

Page 50: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Move things around, from the linearity of XOR

Page 51: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Move things around, from the linearity of XOR

𝜀

Page 52: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Move things around, from the linearity of XOR

𝜀 𝜀

Page 53: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Move things around, from the linearity of XOR

𝜀 𝜀

Lets us search over 8 possible bits instead of 5123

3 bit

combinations.

Page 54: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Similar idea for ChaCha, but involves more bits because of a more involved state update function.

Page 55: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Similar idea for ChaCha, but involves more bits because of a more involved state update function.

“Unlike Salsa20, our exhaustive search showed no bias in 4-round ChaCha, be it with one, two, or three target output bits.”

Page 56: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

Tsunoo et al. (2007) 2−5.24

Aumasson et al. (2008) 2−2.93

Maitra, Paul, Meier (2015) 2−2.35

Maitra (2016) 2−2.12

Reference 𝜀

Fischer et al. (2006) 2−10.34

Maitra, Paul, Meier (2015) 2−9.05

Salsa

4 rounds

5 rounds

Page 57: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

Tsunoo et al. (2007) 2−5.24

Aumasson et al. (2008) 2−2.93

Maitra, Paul, Meier (2015) 2−2.35

Maitra (2016) 2−2.12

This work ≈ 𝟐𝟎

Reference 𝜀

Fischer et al. (2006) 2−10.34

Maitra, Paul, Meier (2015) 2−9.05

This work ≈ 𝟐−𝟑.𝟏𝟑

Salsa

4 rounds

5 rounds

Page 58: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

Tsunoo et al. (2007) 2−5.24

Aumasson et al. (2008) 2−2.93

Maitra, Paul, Meier (2015) 2−2.35

Maitra (2016) 2−2.12

This work ≈ 𝟐𝟎

Reference 𝜀

Fischer et al. (2006) 2−10.34

Maitra, Paul, Meier (2015) 2−9.05

This work ≈ 𝟐−𝟑.𝟏𝟑

Salsa

Reference 𝜀

Aumasson et al. (2008) 2−5.26

Maitra (2016) 2−2.83

Reference 𝜀

ChaCha

4 rounds

5 rounds

3 rounds

4 rounds

Page 59: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

Tsunoo et al. (2007) 2−5.24

Aumasson et al. (2008) 2−2.93

Maitra, Paul, Meier (2015) 2−2.35

Maitra (2016) 2−2.12

This work ≈ 𝟐𝟎

Reference 𝜀

Fischer et al. (2006) 2−10.34

Maitra, Paul, Meier (2015) 2−9.05

This work ≈ 𝟐−𝟑.𝟏𝟑

Salsa

Reference 𝜀

Aumasson et al. (2008) 2−5.26

Maitra (2016) 2−2.83

This work 𝟐𝟎

Reference 𝜀

This work ≈ 𝟐−𝟐.𝟑𝟑

ChaCha

4 rounds

5 rounds

3 rounds

4 rounds

Page 60: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

Tsunoo et al. (2007) 2−5.24

Aumasson et al. (2008) 2−2.93

Maitra, Paul, Meier (2015) 2−2.35

Maitra (2016) 2−2.12

This work ≈ 𝟐𝟎

Reference 𝜀

Fischer et al. (2006) 2−10.34

Maitra, Paul, Meier (2015) 2−9.05

This work ≈ 𝟐−𝟑.𝟏𝟑

Salsa

Reference 𝜀

Aumasson et al. (2008) 2−5.26

Maitra (2016) 2−2.83

This work 𝟐𝟎

Reference 𝜀

This work ≈ 𝟐−𝟐.𝟑𝟑

ChaCha

4 rounds

5 rounds

3 rounds

4 rounds

Distinguisher with complexity ≈ 28

247 improvement

Page 61: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

Tsunoo et al. (2007) 2−5.24

Aumasson et al. (2008) 2−2.93

Maitra, Paul, Meier (2015) 2−2.35

Maitra (2016) 2−2.12

This work ≈ 𝟐𝟎

Reference 𝜀

Fischer et al. (2006) 2−10.34

Maitra, Paul, Meier (2015) 2−9.05

This work ≈ 𝟐−𝟑.𝟏𝟑

Salsa

Reference 𝜀

Aumasson et al. (2008) 2−5.26

Maitra (2016) 2−2.83

This work 𝟐𝟎

Reference 𝜀

This work ≈ 𝟐−𝟐.𝟑𝟑

ChaCha

4 rounds

5 rounds

3 rounds

4 rounds

Distinguisher with complexity ≈ 28

247 improvement

Distinguisher with complexity ≈ 26

Page 62: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 < 1

Page 63: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 < 1

Page 64: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 < 1

Page 65: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 < 1

Page 66: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Linear approximation with 𝜀𝐿 < 1

Page 67: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about
Page 68: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about
Page 69: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about
Page 70: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about
Page 71: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Combination of 19 bits from the subsequent round

Page 72: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

This work ≈ 𝟐−𝟏𝟓.𝟏𝟑

Reference 𝜀

This work ≈ 𝟐−𝟗𝟓.𝟏𝟑

Salsa

6 rounds 7 rounds

Page 73: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

This work ≈ 𝟐−𝟏𝟓.𝟏𝟑

Reference 𝜀

This work ≈ 𝟐−𝟗𝟓.𝟏𝟑

Salsa

Reference 𝜀

This work ≈ 𝟐−𝟕.𝟐

Reference 𝜀

This work ≈ 𝟐−𝟓𝟕.𝟐

ChaCha

6 rounds 7 rounds

5 rounds 6 rounds

Page 74: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

This work ≈ 𝟐−𝟏𝟓.𝟏𝟑

Reference 𝜀

This work ≈ 𝟐−𝟗𝟓.𝟏𝟑

Salsa

Reference 𝜀

This work ≈ 𝟐−𝟕.𝟐

Reference 𝜀

This work ≈ 𝟐−𝟓𝟕.𝟐

ChaCha

6 rounds 7 rounds

5 rounds 6 rounds

Distinguisher with complexity ≈ 232

241 improvement

Page 75: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

This work ≈ 𝟐−𝟏𝟓.𝟏𝟑

Reference 𝜀

This work ≈ 𝟐−𝟗𝟓.𝟏𝟑

Salsa

Reference 𝜀

This work ≈ 𝟐−𝟕.𝟐

Reference 𝜀

This work ≈ 𝟐−𝟓𝟕.𝟐

ChaCha

6 rounds 7 rounds

5 rounds 6 rounds

Distinguisher with complexity ≈ 232

241 improvement

Distinguisher with complexity ≈ 216

Page 76: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference 𝜀

This work ≈ 𝟐−𝟏𝟓.𝟏𝟑

Reference 𝜀

This work ≈ 𝟐−𝟗𝟓.𝟏𝟑

Salsa

Reference 𝜀

This work ≈ 𝟐−𝟕.𝟐

Reference 𝜀

This work ≈ 𝟐−𝟓𝟕.𝟐

ChaCha

6 rounds 7 rounds

5 rounds 6 rounds

Distinguisher with complexity ≈ 232

241 improvement

Distinguisher with complexity ≈ 216 Distinguisher with complexity ≈ 2116

220 improvement

Page 77: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Implications to the key recovery attack

Page 78: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

Page 79: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

6 rounds

Page 80: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

6 rounds

Page 81: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

6 rounds

But...

Page 82: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

6 rounds 2 rounds

Page 83: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Salsa

4 rounds 4 rounds

5 rounds 3 rounds

Page 84: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

4 rounds3 rounds

ChaCha

Page 85: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

4 rounds3 rounds

ChaCha

2.5 rounds4.5 rounds

Page 86: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference Time

Aumasson et al. (2008) 2151

Shi et al. (2012) 2148

Reference Time

Aumasson et al. (2008) 2251

Shi et al. (2012) 2250

Maitra(2016) 2245.5

Salsa

7 rounds

8 rounds

Page 87: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference Time

Aumasson et al. (2008) 2151

Shi et al. (2012) 2148

This work 𝟐𝟏𝟑𝟕

Reference Time

Aumasson et al. (2008) 2251

Shi et al. (2012) 2250

Maitra(2016) 2245.5

This work 𝟐𝟐𝟒𝟒.𝟗

Salsa

7 rounds

8 rounds

Page 88: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference Time

Aumasson et al. (2008) 2151

Shi et al. (2012) 2148

This work 𝟐𝟏𝟑𝟕

Reference Time

Aumasson et al. (2008) 2251

Shi et al. (2012) 2250

Maitra(2016) 2245.5

This work 𝟐𝟐𝟒𝟒.𝟗

Salsa

Reference Time

Aumasson et al. (2008) 2139

Shi et al. (2012) 2136

Reference Time

Aumasson et al. (2008) 2248

Shi et al. (2012) 2246.5

Maitra(2016) 2238.9

ChaCha

7 rounds

8 rounds

6 rounds

7 rounds

Page 89: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Reference Time

Aumasson et al. (2008) 2151

Shi et al. (2012) 2148

This work 𝟐𝟏𝟑𝟕

Reference Time

Aumasson et al. (2008) 2251

Shi et al. (2012) 2250

Maitra(2016) 2245.5

This work 𝟐𝟐𝟒𝟒.𝟗

Salsa

Reference Time

Aumasson et al. (2008) 2139

Shi et al. (2012) 2136

This work 𝟐𝟏𝟐𝟕.𝟓

Reference Time

Aumasson et al. (2008) 2248

Shi et al. (2012) 2246.5

Maitra(2016) 2238.9

This work 𝟐𝟐𝟑𝟕.𝟕

ChaCha

7 rounds

8 rounds

6 rounds

7 rounds

Page 90: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Conclusion

Page 91: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about
Page 92: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

We obtain biases in Salsa and ChaCha not obtained for almost a decade. Develop a theory on how to do this.

Page 93: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

We obtain biases in Salsa and ChaCha not obtained for almost a decade. Develop a theory on how to do this.

Improve attacks on some reduced round versions, importantly moving some to practical realms.

Page 94: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

We obtain biases in Salsa and ChaCha not obtained for almost a decade. Develop a theory on how to do this.

Improve attacks on some reduced round versions, importantly moving some to practical realms.

A different method to partition the key space could potentially improve our attacks in both complexity and rounds.

Page 95: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

We obtain biases in Salsa and ChaCha not obtained for almost a decade. Develop a theory on how to do this.

Improve attacks on some reduced round versions, importantly moving some to practical realms.

A different method to partition the key space could potentially improve our attacks in both complexity and rounds.

(or is this inherent to this kind of cryptanalysis?)

Page 96: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

Thank you. Questions?

Page 97: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

References

Page 98: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

[C05] Paul Crowley. “Truncated differential cryptanalysis of five rounds of Salsa20". In: IACR Cryptology ePrint Archive 2005 (2005), p. 375. url: http : / /eprint.iacr.org/2005/375.

[FMB+06] Simon Fischer, Willi Meier, Come Berbain, Jean-Francois Biasse, and Matthew J. B. Robshaw. “Non-randomness in eSTREAM Candidates Salsa20 and TSC-4". In: Progress in Cryptology - INDOCRYPT 2006, 7th International Conference on Cryptology in India, Kolkata, India, December 11-13, 2006, Proceedings.

[TSK+07] Yukiyasu Tsunoo, Teruo Saito, Hiroyasu Kubo, Tomoyasu Suzaki, and Hiroki Nakashima. “Differential Cryptanalysis of Salsa20/8”. 2007. url: http://ecrypt.eu.org/stream/papersdir/2007/010.pdf.

[AFK+08] Jean-Philippe Aumasson, Simon Fischer, Shahram Khazaei, Willi Meier, and Christian Rechberger. “New features of Latin dances: analysis of Salsa, ChaCha, and Rumba". In: Fast Software Encryption. Springer. 2008.

[SZF+12] Zhenqing Shi, Bin Zhang, Dengguo Feng, and Wenling Wu. “Improved Key Recovery Attacks on Reduced-Round Salsa20 and ChaCha". In: Information Security and Cryptology - ICISC 2012 - 15th International Conference, Seoul, Korea, November 28-30, 2012, Revised Selected Papers.

Page 99: Significantly Improved Multi- bit Differentials for ...achoud/FSE2017_talk.pdfSalsa accepted into the eStream software portfolio (2007). ChaCha designed to address some concerns about

[MPM15] Subhamoy Maitra, Goutam Paul, and Willi Meier. “Salsa20 Cryptanalysis: New Moves and Revisiting Old Styles". In: WCC 2015, the Ninth International Workshop on Coding and Cryptography, April 13-17, 2015, Paris, France.

[Mai16] Subhamoy Maitra. “Chosen IV cryptanalysis on reduced round ChaCha and Salsa". In: Discrete Applied Mathematics 208 (2016).