Authenticated ciphers D. J. Bernstein University of Illinois at - - PDF document

authenticated ciphers d j bernstein university of
SMART_READER_LITE
LIVE PREVIEW

Authenticated ciphers D. J. Bernstein University of Illinois at - - PDF document

Authenticated ciphers D. J. Bernstein University of Illinois at Chicago Joint work with: Tanja Lange Technische Universiteit Eindhoven Advertisement: SHARCS 2012 (Special-Purpose Hardware for Attacking Cryptographic Systems) is right before


slide-1
SLIDE 1

Authenticated ciphers

  • D. J. Bernstein

University of Illinois at Chicago Joint work with: Tanja Lange Technische Universiteit Eindhoven Advertisement: SHARCS 2012 (Special-Purpose Hardware for Attacking Cryptographic Systems) is right before FSE+SHA-3. 2012.01.23 deadline to submit extended abstracts. 2012.sharcs.org

slide-2
SLIDE 2

Multiple-year SHA-3 competition has produced a natural focus for security analysis and performance analysis. Community shares an interest in selecting best hash as SHA-3. Intensive analysis of candidates: hash conferences, hash workshops, active SHA-3 mailing list, etc. Would have been harder to absorb same work spread over more conferences, more time. Focus improves community’s understanding and confidence.

slide-3
SLIDE 3

This is a familiar pattern. June 1998: AES block-cipher submissions from 50 people ✮ community focus. April 2005: eSTREAM stream- cipher submissions from 100 people ✮ community focus. October 2008: SHA-3 hash- function submissions from 200 people ✮ community focus.

slide-4
SLIDE 4

This is a familiar pattern. June 1998: AES block-cipher submissions from 50 people ✮ community focus. April 2005: eSTREAM stream- cipher submissions from 100 people ✮ community focus. October 2008: SHA-3 hash- function submissions from 200 people ✮ community focus. NESSIE was much less focused and ended up in more trouble: e.g., only two MAC submissions.

slide-5
SLIDE 5

The next community focus What’s next after block ciphers, stream ciphers, hash functions? Proposal: authenticated ciphers. Basic security goal: two users start with a shared secret key; then want to protect messages against espionage and forgery. The usual competition: maximize security subject to performance constraints; i.e.: maximize performance subject to security constraints.

slide-6
SLIDE 6

“Isn’t authenticated encryption done already?”

slide-7
SLIDE 7

“Isn’t authenticated encryption done already?” FSE 2011 Krovetz–Rogaway cite EtM, RPC, IAPM, XCBC, OCB1, TAE, CCM, CWC, GCM, EAX, OCB2, CCFB, CHM, SIV, CIP, HBS, BTM; and propose OCB3. Same paper reports various timings for AES-GCM; better timings for AES-OCB3, “the fastest reported times for AE” (authenticated encryption); within ✎ of AES.

slide-8
SLIDE 8

“Isn’t authenticated encryption done already?” FSE 2011 Krovetz–Rogaway cite EtM, RPC, IAPM, XCBC, OCB1, TAE, CCM, CWC, GCM, EAX, OCB2, CCFB, CHM, SIV, CIP, HBS, BTM; and propose OCB3. Same paper reports various timings for AES-GCM; better timings for AES-OCB3, “the fastest reported times for AE” (authenticated encryption); within ✎ of AES. “That’s the end! AES-OCB3!”

slide-9
SLIDE 9

General themes of next several slides in this talk:

  • 1. Is AES-OCB3 the best way

to build an authenticated cipher? Many reasons to be skeptical.

slide-10
SLIDE 10

General themes of next several slides in this talk:

  • 1. Is AES-OCB3 the best way

to build an authenticated cipher? Many reasons to be skeptical.

  • 2. Examples of how

earlier authenticated ciphers already beat AES-OCB3

slide-11
SLIDE 11

General themes of next several slides in this talk:

  • 1. Is AES-OCB3 the best way

to build an authenticated cipher? Many reasons to be skeptical.

  • 2. Examples of how

earlier authenticated ciphers already beat AES-OCB3 ✿ ✿ ✿ in some respects.

slide-12
SLIDE 12

General themes of next several slides in this talk:

  • 1. Is AES-OCB3 the best way

to build an authenticated cipher? Many reasons to be skeptical.

  • 2. Examples of how

earlier authenticated ciphers already beat AES-OCB3 ✿ ✿ ✿ in some respects. Conclusion: No reason to think that existing work is optimal. Ample room for competition.

slide-13
SLIDE 13

Changing the components AES-GCM uses AES-CTR. Many bits of AES input thus end up as constants, invalidating many differentials. Can AES-GCM get away with

  • ne or two fewer AES rounds

while still providing security against differential attacks? AES-OCB3 doesn’t use CTR. Can it be safely modified to use some constant bits?

slide-14
SLIDE 14

We know more about ciphers in 2012 than we did in 1998. Can we obtain better speeds by replacing AES with another block cipher?

slide-15
SLIDE 15

We know more about ciphers in 2012 than we did in 1998. Can we obtain better speeds by replacing AES with another block cipher? Can we obtain better speeds by replacing AES-CTR with another stream cipher?

slide-16
SLIDE 16

We know more about ciphers in 2012 than we did in 1998. Can we obtain better speeds by replacing AES with another block cipher? Can we obtain better speeds by replacing AES-CTR with another stream cipher? Yes, course! See eSTREAM. Example, ARM Cortex A8: 28.9 cycles/byte for AES-OCB3. 25.4 cycles/byte for AES-CTR. 8.53 cycles/byte for Salsa20/20. 5.53 cycles/byte for Salsa20/12.

slide-17
SLIDE 17

How expensive are MACs? Can take any modern hash (or design another one!), plug into HMAC.

slide-18
SLIDE 18

How expensive are MACs? Can take any modern hash (or design another one!), plug into HMAC. Are universal hashes better? GCM’s universal hash: faster than HMAC in hardware but much slower in software.

slide-19
SLIDE 19

How expensive are MACs? Can take any modern hash (or design another one!), plug into HMAC. Are universal hashes better? GCM’s universal hash: faster than HMAC in hardware but much slower in software. UMAC, VMAC, etc.: faster than HMAC in software; what about hardware? (I’m doing a new PEMA design.)

slide-20
SLIDE 20

Improving security AES-GCM, AES-OCB3, etc. advertise “provable security” if AES is secure.

slide-21
SLIDE 21

Improving security AES-GCM, AES-OCB3, etc. advertise “provable security” if AES is secure. But is AES actually secure? Are the latest AES-cryptanalysis papers reason for concern? (I don’t think so, but maybe you disagree.)

slide-22
SLIDE 22

Improving security AES-GCM, AES-OCB3, etc. advertise “provable security” if AES is secure. But is AES actually secure? Are the latest AES-cryptanalysis papers reason for concern? (I don’t think so, but maybe you disagree.) Does efficiency force ciphers to have a scary key schedule?

slide-23
SLIDE 23

What happens to security if there are many messages?

slide-24
SLIDE 24

What happens to security if there are many messages? Usually the security proofs become meaningless. e.g. AES-OCB3 theorems allow attack probability 6q2❂2128 after q blocks of AES input. Is q ✙ 260 so hard to imagine?

slide-25
SLIDE 25

What happens to security if there are many messages? Usually the security proofs become meaningless. e.g. AES-OCB3 theorems allow attack probability 6q2❂2128 after q blocks of AES input. Is q ✙ 260 so hard to imagine? 128-bit block size for AES is beginning to look rather small. Wouldn’t it be more comfortable to have 256-bit blocks?

slide-26
SLIDE 26

What happens to security if the attacker is lucky and succeeds at one forgery? AES-GCM answer: key recovery. AES-OCB3 answer: ?

slide-27
SLIDE 27

What happens to security if the attacker is lucky and succeeds at one forgery? AES-GCM answer: key recovery. AES-OCB3 answer: ? Can limit the damage by rejecting old nonces and deriving key from nonce; but this creates speed problems for AES, bigger speed problems for GCM.

slide-28
SLIDE 28

What happens to security if the attacker is lucky and succeeds at one forgery? AES-GCM answer: key recovery. AES-OCB3 answer: ? Can limit the damage by rejecting old nonces and deriving key from nonce; but this creates speed problems for AES, bigger speed problems for GCM. How important is this? Do we need high key agility?

slide-29
SLIDE 29

What about side-channel attacks? Not a strong point for AES. Not a strong point for GCM.

slide-30
SLIDE 30

What about side-channel attacks? Not a strong point for AES. Not a strong point for GCM. We understand reasonably well how to design primitives to avoid software side channels.

slide-31
SLIDE 31

What about side-channel attacks? Not a strong point for AES. Not a strong point for GCM. We understand reasonably well how to design primitives to avoid software side channels. How can we design primitives to reduce cost of avoiding hardware side channels? One approach (e.g., Keccak): maximize bit-level parallelism, minimize degree over F2.

slide-32
SLIDE 32

Cost metrics Is time the most important metric for performance?

slide-33
SLIDE 33

Cost metrics Is time the most important metric for performance? Does your cryptography fit

  • nto an RFID, or

into a small corner of a CPU? What is the smallest area for an authenticated cipher?

slide-34
SLIDE 34

Cost metrics Is time the most important metric for performance? Does your cryptography fit

  • nto an RFID, or

into a small corner of a CPU? What is the smallest area for an authenticated cipher? For each ❆: How fast is an authenticated cipher that fits into area ❆?

slide-35
SLIDE 35

Is AES-OCB3 actually faster than AES-GCM at rejecting forgeries?

slide-36
SLIDE 36

Is AES-OCB3 actually faster than AES-GCM at rejecting forgeries? AES-GCM rejects forgery with no decryption time. AES-OCB3 is faster than AES-GCM, but is it faster than just the MAC in AES-GCM?

slide-37
SLIDE 37

Is AES-OCB3 actually faster than AES-GCM at rejecting forgeries? AES-GCM rejects forgery with no decryption time. AES-OCB3 is faster than AES-GCM, but is it faster than just the MAC in AES-GCM? Many other MACs are clearly faster than AES-OCB3.

slide-38
SLIDE 38

Is AES-OCB3 actually faster than AES-GCM at rejecting forgeries? AES-GCM rejects forgery with no decryption time. AES-OCB3 is faster than AES-GCM, but is it faster than just the MAC in AES-GCM? Many other MACs are clearly faster than AES-OCB3. What is most important for performance of authenticated ciphers: normal traffic, or floods of forged traffic?

slide-39
SLIDE 39

AES-OCB3 saves time in encryption and decryption by building a MAC that “accidentally” also computes a ciphertext.

slide-40
SLIDE 40

AES-OCB3 saves time in encryption and decryption by building a MAC that “accidentally” also computes a ciphertext. Can we build a cipher that “accidentally” also computes a fast MAC?

slide-41
SLIDE 41

AES-OCB3 saves time in encryption and decryption by building a MAC that “accidentally” also computes a ciphertext. Can we build a cipher that “accidentally” also computes a fast MAC? Fast MAC of ♠0❀ ♠1❀ ✿ ✿ ✿ typically looks like ❦0♠0 + ❦1♠1 + ✁ ✁ ✁. Use ❦✐♠✐ in computing ✐th block of ciphertext? Compare to 1996 Lucks ❍❋❋.

slide-42
SLIDE 42

Another approach (e.g., Helix, Phelix, Keccak): map state, plaintext block to new state, ciphertext block.

slide-43
SLIDE 43

Another approach (e.g., Helix, Phelix, Keccak): map state, plaintext block to new state, ciphertext block. Complaint about Helix/Phelix: state-recovery attack if user repeats nonces for different plaintexts chosen by the attacker.

slide-44
SLIDE 44

Another approach (e.g., Helix, Phelix, Keccak): map state, plaintext block to new state, ciphertext block. Complaint about Helix/Phelix: state-recovery attack if user repeats nonces for different plaintexts chosen by the attacker. Does this actually matter? Fix 1: Give up, and stop feeding plaintext into state. Fix 2: Use much larger blocks, much stronger map.

slide-45
SLIDE 45

Isn’t this fun? Authenticated-cipher competition, like hash-function competition, is much more than mode competition.

slide-46
SLIDE 46

Isn’t this fun? Authenticated-cipher competition, like hash-function competition, is much more than mode competition. Want to build a better cipher? Combine with any standard MAC, submit to the competition.

slide-47
SLIDE 47

Isn’t this fun? Authenticated-cipher competition, like hash-function competition, is much more than mode competition. Want to build a better cipher? Combine with any standard MAC, submit to the competition. Want to build a better MAC? Combine with AES, submit.

slide-48
SLIDE 48

Isn’t this fun? Authenticated-cipher competition, like hash-function competition, is much more than mode competition. Want to build a better cipher? Combine with any standard MAC, submit to the competition. Want to build a better MAC? Combine with AES, submit. Oh, you are a mode designer? Take standard components, submit.

slide-49
SLIDE 49

Suggested timeline

slide-50
SLIDE 50

Suggested timeline First and most important: Stop thinking about SHA-3.

slide-51
SLIDE 51

Suggested timeline First and most important: Stop thinking about SHA-3. Second half of 2012: Public discussion of requirements. Much easier than for hashing, but still some real questions: e.g., how much damage is okay if nonces are reused?

slide-52
SLIDE 52

Suggested timeline First and most important: Stop thinking about SHA-3. Second half of 2012: Public discussion of requirements. Much easier than for hashing, but still some real questions: e.g., how much damage is okay if nonces are reused? Mid-2012: ECRYPT workshop. Mid-2013: Submission deadline. Mid-2014: Second round. Mid-2015: Third round.

slide-53
SLIDE 53

Most work is volunteered by cryptographers+cryptanalysts designing+attacking submissions. (And we’ll do benchmarking.) Also need central committee

  • f experienced cryptologists

evaluating cryptanalyses and selecting the best submissions. Is this committee work so much fun that the right people will volunteer for it? Maybe!

slide-54
SLIDE 54

Competition name “AES”: “Authenticated Encryption Standard”?

slide-55
SLIDE 55

Competition name “AES”: “Authenticated Encryption Standard”? “AACS”: “Advanced Authenticated Cipher Standard”?

slide-56
SLIDE 56

Competition name “AES”: “Authenticated Encryption Standard”? “AACS”: “Advanced Authenticated Cipher Standard”? “aSTREAM”?

slide-57
SLIDE 57

Competition name “AES”: “Authenticated Encryption Standard”? “AACS”: “Advanced Authenticated Cipher Standard”? “aSTREAM”? “YACC”?

slide-58
SLIDE 58

Competition name “AES”: “Authenticated Encryption Standard”? “AACS”: “Advanced Authenticated Cipher Standard”? “aSTREAM”? “YACC”? “AEAAEADAOIAIP”?

slide-59
SLIDE 59

Competition name “AES”: “Authenticated Encryption Standard”? “AACS”: “Advanced Authenticated Cipher Standard”? “aSTREAM”? “YACC”? “AEAAEADAOIAIP”? Greg Rose has suggested “eSAFE”. Maybe “ECRYPT Secure Authenticated Fast Encryption”?

slide-60
SLIDE 60

Competition name “AES”: “Authenticated Encryption Standard”? “AACS”: “Advanced Authenticated Cipher Standard”? “aSTREAM”? “YACC”? “AEAAEADAOIAIP”? Greg Rose has suggested “eSAFE”. Maybe “ECRYPT Secure Authenticated Fast Encryption”? Orr: “FEAR”? “SHÆ-3”?

slide-61
SLIDE 61