Application of cube attack to block and stream ciphers



Similar documents
On the Influence of the Algebraic Degree of the Algebraic Degree of

Lecture Note 8 ATTACKS ON CRYPTOSYSTEMS I. Sourav Mukhopadhyay

Cryptography and Network Security Chapter 3

Cryptography and Network Security

Table of Contents. Bibliografische Informationen digitalisiert durch

How To Understand And Understand The History Of Cryptography

Advanced Cryptography

How To Encrypt With A 64 Bit Block Cipher

The Advanced Encryption Standard: Four Years On

CSCE 465 Computer & Network Security

The Stream Cipher HC-128

2.3. Finding polynomial functions. An Introduction:

Network Security: Cryptography CS/SS G513 S.K. Sahay

1 Data Encryption Algorithm

CS 758: Cryptography / Network Security

VoteID 2011 Internet Voting System with Cast as Intended Verification

KALE: A High-Degree Algebraic-Resistant Variant of The Advanced Encryption Standard

Network Security. Computer Networking Lecture 08. March 19, HKU SPACE Community College. HKU SPACE CC CN Lecture 08 1/23

INTERPOLATION. Interpolation is a process of finding a formula (often a polynomial) whose graph will pass through a given set of points (x, y).

Modern Block Cipher Standards (AES) Debdeep Mukhopadhyay

Masao KASAHARA. Public Key Cryptosystem, Error-Correcting Code, Reed-Solomon code, CBPKC, McEliece PKC.

Cryptography and Network Security. Prof. D. Mukhopadhyay. Department of Computer Science and Engineering. Indian Institute of Technology, Kharagpur

Network Security Technology Network Management

Cryptography and Network Security Block Cipher

Enhancing Advanced Encryption Standard S-Box Generation Based on Round Key

Dr. Jinyuan (Stella) Sun Dept. of Electrical Engineering and Computer Science University of Tennessee Fall 2010

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur

Overview of Cryptographic Tools for Data Security. Murat Kantarcioglu

Network Security. Chapter 3 Symmetric Cryptography. Symmetric Encryption. Modes of Encryption. Symmetric Block Ciphers - Modes of Encryption ECB (1)

Secret File Sharing Techniques using AES algorithm. C. Navya Latha Garima Agarwal Anila Kumar GVN

The Advanced Encryption Standard (AES)

SOLVING POLYNOMIAL EQUATIONS

Network Security. HIT Shimrit Tzur-David

CIS 6930 Emerging Topics in Network Security. Topic 2. Network Security Primitives

The 128-bit Blockcipher CLEFIA Design Rationale

CIS433/533 - Computer and Network Security Cryptography

A NEW HASH ALGORITHM: Khichidi-1

EXAM questions for the course TTM Information Security June Part 1

Cryptography and Network Security Department of Computer Science and Engineering Indian Institute of Technology Kharagpur

Ky Vu DeVry University, Atlanta Georgia College of Arts & Science

JUST THE MATHS UNIT NUMBER 1.8. ALGEBRA 8 (Polynomials) A.J.Hobson

RSA Attacks. By Abdulaziz Alrasheed and Fatima

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur

Network Security. Security. Security Services. Crytographic algorithms. privacy authenticity Message integrity. Public key (RSA) Message digest (MD5)

IT Networks & Security CERT Luncheon Series: Cryptography

A PPENDIX H RITERIA FOR AES E VALUATION C RITERIA FOR

A New 128-bit Key Stream Cipher LEX

A PPENDIX G S IMPLIFIED DES

Block encryption. CS-4920: Lecture 7 Secret key cryptography. Determining the plaintext ciphertext mapping. CS4920-Lecture 7 4/1/2015

Part I. Universität Klagenfurt - IWAS Multimedia Kommunikation (VK) M. Euchner; Mai Siemens AG 2001, ICN M NT

{(i,j) 1 < i,j < n} pairs, X and X i, such that X and X i differ. exclusive-or sums. ( ) ( i ) V = f x f x

Network Security CS 5490/6490 Fall 2015 Lecture Notes 8/26/2015

Developing and Investigation of a New Technique Combining Message Authentication and Encryption

1 Lecture: Integration of rational functions by decomposition

7! Cryptographic Techniques! A Brief Introduction

CSCE 465 Computer & Network Security

Physical-Layer Security: Combining Error Control Coding and Cryptography

Factoring. Factoring 1

Chapter 11 Security+ Guide to Network Security Fundamentals, Third Edition Basic Cryptography

Security Evaluation of the SPECTR-128. Block Cipher

SFLASH v3, a fast asymmetric signature scheme

A Practical Attack on Broadcast RC4

Cryptanalysis of Grain using Time / Memory / Data Tradeoffs

Network Security. Security Attacks. Normal flow: Interruption: 孫 宏 民 Phone: 國 立 清 華 大 學 資 訊 工 程 系 資 訊 安 全 實 驗 室

Cryptography & Network Security

Lagrange Interpolation is a method of fitting an equation to a set of points that functions well when there are few points given.

Split Based Encryption in Secure File Transfer

Mathematical Model Based Total Security System with Qualitative and Quantitative Data of Human

Symmetric Key cryptosystem

Lecture 4 Data Encryption Standard (DES)

Multi-Layered Cryptographic Processor for Network Security

Unknown Plaintext Template Attacks

3-6 Toward Realizing Privacy-Preserving IP-Traceback

SOLVING SEXTIC EQUATIONS. Raghavendra G. Kulkarni

CRYPTOG NETWORK SECURITY

Cryptosystems. Bob wants to send a message M to Alice. Symmetric ciphers: Bob and Alice both share a secret key, K.

Analysis of Non-fortuitous Predictive States of the RC4 Keystream Generator

MAC. SKE in Practice. Lecture 5

Message Authentication Codes

CRYPTOGRAPHY IN NETWORK SECURITY

Computer Networks. Network Security 1. Professor Richard Harris School of Engineering and Advanced Technology

Cryptography: Motivation. Data Structures and Algorithms Cryptography. Secret Writing Methods. Many areas have sensitive information, e.g.

FAREY FRACTION BASED VECTOR PROCESSING FOR SECURE DATA TRANSMISSION

Lukasz Pater CMMS Administrator and Developer

Indiana State Core Curriculum Standards updated 2009 Algebra I

Cryptography and Network Security Chapter 9

Rijndael Encryption implementation on different platforms, with emphasis on performance

expression is written horizontally. The Last terms ((2)( 4)) because they are the last terms of the two polynomials. This is called the FOIL method.

Introduction. Where Is The Threat? Encryption Methods for Protecting Data. BOSaNOVA, Inc. Phone: Web:

SECURITY IMPROVMENTS TO THE DIFFIE-HELLMAN SCHEMES

Transcription:

Application of cube attack to block and stream ciphers Janusz Szmidt joint work with Piotr Mroczkowski Military University of Technology Military Telecommunication Institute Poland 23 czerwca 2009

1. Papers ItaiDinurandAdiShamir,CubeAttackson Tweakable Black Box Polynomials, Eurocrypt, 2009. S.S.BediandR.Pillai,CubeattacksonTrivium, IACR Cryptology eprint Archive, 2009/15. J-P. Aumasson, W. Meier, I. Dinur, A. Shamir, Cube testers and key recovery attacks on reduced round MD6 and Trivium, Fast Software Encryption, 2009. I. Dinur, A. Shamir, Side channel cube attacks on block ciphers, IACR Cryptology eprint Archive, 2009/127. J. Lathrop, Cube Attacks on Cryptographic Hash Functions, Master s Thesis, Rochester Institte of Technology, 2009.

Paper Miachael Vielhaber, Breaking One.Fivium by AIDA an Algebraic IV Differential Attack, IACR Cryptology eprint Archive, 2007.

2. The structure of attack Let us consider cryptosystem described by the polynomial: p(v 1,...,v m,x 1,...,x n ) dependingonmpublicvariablesv 1,...,v m (theinitial valueorplaintext)andonnsecretvariablesx 1,...,x n (thekey). The value of the polynomial represents the ciphertext bit. In general, the polynomial p is not explicitelly known; it canbeablackbox. We will consider the known plaintext attack, where at the preprocessing stage the attacker has also an access to secret variables(initial values or keys).

3. The structure of attack, cont. 1 The preprocessing stage. The attacker can change the valuesofpublicandsecretvariables.thetaskistoobtain a system of linear equations on secret variables. 2 Thestageonlineoftheattack.Thekeyissecret now. The attacker can change the values of public variables. He adds the output bits, where the inputs run over some multi-dimennsional cubes. The task is to obtain the right hand sides of linear equations. The system of linearequationcanbesolvedgivingsomebitsofthekey.

4. Mathematical background Foramomentweshallnotdistinguishthesecretand public variables. Letpbeapolynomialofnvariablesx 1,...,x n overthe fieldgf(2). ForasubsetofindexesI ={i 1,...,i k } {1,...,n}let ustakeamonomial t I =x i1...x ik Then we have a decomposition p(x 1,...,x n ) =t I p S(I) +q(x 1,...,x n ) wherethepolynomialp S(I) doesnotdependonthe variablesx i1,...,x ik.

5.Example1 Letusconsiderapolynomialpofdegree3dependingon 5 variables: p(x 1,x 2,x 3,x 4,x 5 ) =x 1 x 2 x 3 +x 1 x 2 x 4 +x 2 x 4 x 5 + x 1 x 2 +x 3 x 5 +x 2 +x 5 =1 LetI ={1.2}beachosensubsetofindexes. Then the polynomial p can be decomposed as: p(x 1,x 2,x 3,x 4,x 5 ) =x 1 x 2 (x 3 +x 4 +1)+ (x 2 x 4 x 5 +x 3 x 5 +x 2 +x 5 +1)

6. Example 1, cont. Using the introduced above notation: t I =x 1 x 2, p S(I) =x 3 +x 4 +1, q(x 1,x 2,x 3,x 4,x 5 ) =x 2 x 4 x 5 +x 3 x 5 +x 2 +x 5 +1

7. Definition 1 Themaxtermofthepolynomialpwecallthemonomialt I, such that deg(p S(I) ) =1, itmeansthatthepolynomialp S(I) correspondingtothesubset ofindexesiisalinearone,whichisnotaconstant.

8. Summation over cubes LetI ={i 1,...,i k } {1,...,n}beafixedsubsetofk indexes. ThesetIdefinesthek-dimensionalbooleancubeC I, whereontheplaceofeachoftheindexesweput0or1. Agivenvectorv C I definesthederivedpolynomoalp v dependingonn kvariables,whereinthebasic polynomoal p we put the values corresponding to the vectorv. SummingoverallvectorsinthecubeC I weobtainthe polynomial: p I = v C I p v

9.Theorem1 LetpbeapolynomialoverthefieldGF(2)andI {1,...,n} theindexsubset.thenwehave: p I =p S(I) mod2

10. Example 2 Let us consider a polynomial: p(v 1,v 2,v 3,x 1,x 2,x 3 ) =v 1 v 2 v 3 +v 1 v 2 x 1 +v 1 v 3 x 1 +v 2 v 3 x 1 + v 1 v 2 x 3 +v 1 v 3 x 2 +v 2 v 3 x 2 +v 1 v 3 x 3 +v 1 x 1 x 3 +v 3 x 2 x 3 +x 1 x 2 x 3 + v 1 v 2 +v 1 x 3 +v 3 x 1 +x 1 x 2 +x 2 x 3 +x 2 +v 1 +v 3 +1 ofdegreed=3dependingonpublicvariablesv 1,v 2,v 3 andsecretvariablesx 1,x 2,x 3. Substituting on public variables the values 0/1 we get the eight derived polynomials.

11. Example 2, cont. p(0,0,0,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 2 x 3 +x 2 +1 p(0,0,1,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 1 +x 2 p(0,1,0,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 2 x 3 +x 2 +1 p(0,1,1,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 p(1,0,0,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 1 x 3 +x 2 x 3 +x 2 +x 3 p(1,0,1,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 1 x 3 +1 p(1,1,0,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 1 x 3 +x 2 x 3 +x 1 +x 2 +1 p(1,1,1,x 1,x 2,x 3 ) =x 1 x 2 x 3 +x 1 x 2 +x 1 x 3 +x 2 +x 3 +1

12. Example 2, cont. Summingthefourderivedpolynomialswithv 1 =0weget x 1 +x 2, Summingthefourderivedpolynomialswithv 2 =0weget x 1 +x 2 +x 3, Summingthefourderivedpolynomialswithv 3 =0weget x 1 +x 3 +1. The obtained expressions lead to a system of linear equationsusedinthestageonlineoftheattack.

13. The preprocessing stage 1 Thefirsttaskistofixdimensionofthecubeandthe public variables over which we will sum; they are called the tweakable variables, and the other public variables are puttozero.inthecaseweknowthedegreedofthe basicpolynomial,weputthecubedimensiontod 1. 2 Wedothesummationoverafixedcubeforseveralvalues of secret variables and collect the obtained values. 3 Wedothelineartestsfortheobtainedfunctionofsecret variablesandstoreitwhenitislinear: f (x x ) =f (x) f(x ) f(0), wherex= (x 1,...,x n )aresecretvariables(thekey).

14. The preprocessing stage, cont. Thenexttaskistocalculatetheexactform(the coefficients) of the obtained linear function of secret variables. Thefreetermofthelinearfunctionweobtanputtingits all argument equal zero. Thecoefficientofthevariablex i isequal1ifandonlyif thechangeofthisvariableimpliesthechangeofvaluesof the function. Thecoefficientofthevariablex i isequal0ifandonlyif thechangeofthisvariabledoesnotimplythechangeof values of the function.

15. The preprocessing stage, cont. Thetaskofthisstageofattackistocollectpossible many independent linear terms- they constitute the system of linear equations on secret variables. Thissystemoflinearequationswillbeusedintheonline stage of attack. The preprocessing stage is done only once in cryptanalysis of the algorithm.

16.Thestageonlineofattack Now an attacker has the access only to public variables (thr plaintext for block ciphers, the initial values for stream ciphers), which he can change and calculates the corresponding bits of the ciphertext under the unknown value of secret variables. Thetaskofthisstageofattackistofindsomebitsof secret key with complexity, which would be lower than the exhuastive search in the brute force attack. The attacker uses the derived system of linear equations for secret variables(the unknown bits of the key), where therighthandsidesoftheseequationsarethevaluesof bits of ciphertext obtained after summation over the same cubesasinthepreprocessingstage,butnowthekeyis not known.

17.Thestageonlineofattack,cont. The cube attach is applicable to symmetric ciphers for which the polynomials descibing the system have relatively low degree. Thenonecaneventuallyfindsomebitsofunknownkey. Theremainingbitsofthekeymaybefoundbybrute force search. After successful preprocwssing stage, the stage on line of attack can be done many times for different unknown keys The cube attack is applicable, in general, to cryptosystems without knowing their inner structure. The attacker must have the possibility to realize the preprocessingstageandintheonlinestageanaccessto the implementation of the algorithm(to perform the summation over cubes under unknown key).

18.CTC-CourtoisToyCipher Specification CTC was designed by Nicolais Courtois to apply and test the methods of algebraic analysis. ItisaSPNnetworkwhichisscalableinthenumberof rounds, the block and key size. Each round performs the same operation on the input data,exceptthatadifferentroundkeyisaddedeach time.thenumberofroundsisdenotedbyn r.the outputofroundi 1istheinputtoroundi. Each round consists of parallel applications of B S-boxes (S), the application of the linear diffusion layer (D), and afinalkeyadditionoftheroundkey.theroundkeyk 0 is added to the plaitext block before the first round.

19.CTCovervievforB=10

20.CTC-CourtoisToyCipher Specyfication, cont. Theplaintextbitsp 0...p Bs 1 areidentifiedwith Z 0,0...Z 0,Bs 1 andtheciphertextbitsc 0...c Bs 1 are identifiedwithx Nr+1,0...X Nr+1,Bs 1tohaveanuniform notation. The S-box was chosen as the permutation [7,6,0,4,2,5,1,3] Ithas2 3 =8inputsand8outputs.Theoutputbitsare quadratic boolean functions of the input bits. The explicit formofthesefunctionsisnotusedincubeattack.

21.CTC-CourtoisToyCipher Specyfication, cont. The diffusion layer (D) is defined as foralli =1...N r, Z i,257modbs =Y i,0 Z i,(1987j+257)modbs =Y i,j +Y i,(j+137)modbs forj 0andalli,whereY i,j representsinputbotsand Z i,j representsoutputbits.

22.CTC-CourtoisToyCipher Specyfication, cont. The key schedule is a simple permutation of bits: K i,j =K 0,(i+j)modBs foralliandj,wherek 0 isthemainkey. Key addition is performed bit-wise: X i+1,j =Z i,j +K i,j foralli =1...N r andj =1...Bs 1,whereZ i,j represents output bits of the previous diffusion layer, X i+1,j theinputbitsofthenextround,andk i,j thebitsof the current round key.

23.CubeattackonCTC WehaveappliedthecubeattacktotheversionofCTC withfourroundsandb=40ofs-boxes,i.e.theblock andthekeysizesbeing120bits. In the preprocessing stage we have done the summation over 50000 randomly chosen four dimensional cubes taken fromtheplaintext(otherbitsoftheplaintextareputto zero). Then 757 boxes lead to linear expresions (maxterms)forbitsofthekey.forderivationofeach linear expresion we used 5000 linear tests. We have chosen 120 linearly independent maxterms. They give the solvable system of linear equation for bits of the key.

24. The linear equations The equation Cube indexes 1+x66+x68 = c66 {4,5,22,52} x27+x28 = c105 {1,60,62,90} 1+x58 = c18 {16,17,60,110} 1+x14 = c80 {29,38,61,106} 1+x54+x56 = c36 {41,55,64,115} 1+x115+x116 = c66 {5,10,22,89} 1+x43 = c11 {73,74,75,118} x69+x70 = c28 {48,68,77,110} 1+x25 = c70 {73,76,93,104} x78+x79 = c114 {10,39,70,118} There are together 120 linearly independent such equations for thebitsx 0,...,x 119 ofthekey;c 0,...,c 119 areoutputbits.

25.CubeattackonCTC,cont. Intheonlinestageoftheattackweneedtosumover 120chosencubes(thekeyisunknown)tofindtheright hand sides of the linear equations. Thecomplexityoftheattackhereisabout2 7 2 4 =2 11 encryptionsofthefourroundctctorecoverthefull 120-bit key. Infact,thisreducedroundcipherisdescribedbyasystem of linear equations. Probably, for biger number of rounds, it is impossible to find such a description.

26.The stream cipher Trivium The specification of algorithm Algorithm Trivium(the authors: C. de Canniere and B. Preneel)isoneofthefinalistsofeSTREAM competitions. Thebasicparametersarethe80-bitkeyandthe80-bit initial value. TheinnerstateofTriviumare288bitsloadedtothree nonlinear registers of different lengths. Ineachroundofthealgorithmtheregistersareshiftedon one bit. Thefeedbackineachregisterisgivenbyanonlinear function.

27. The specification of Trivium (s 1,s 2,...,s 93 ) (k 1,k 2,...,k 80,0,...,0) (s 94,s 95,...,s 177 ) (IV 1,IV 2,...,IV 80,0,...,0) (s 178,s 179,...,s 288 ) (0,0,...,0,1,1,1) fori=1to1152 t 1 s 66 +s 93 t 2 s 162 +s 177 t 3 s 243 +s 288 t 1 t 1 +s 91 s 92 +s 171 t 2 t 2 +s 175 s 176 +s 264 t 3 t 3 +s 286 s 287 +s 69

28. The specification of Trivium, cont. (s 1,s 2,...,s 93 ) (t 3,s 1,...,s 92 ) (s 94,s 95,...,s 177 ) (t 1,s 94,...,s 176 ) (s 178,s 179,...,s 288 ) (t 2,s 178,...,s 287 ) end for

29. The specification of Trivium, cont. Thegenerationoftheouputbtstring (z i )ofthemaximal lengthupto N =2 64 bits,canberepresentedas: fori=1ton t 1 s 66 +s 93 t 2 s 162 +s 177 t 3 s 243 +s 288 z i t 1 +t 2 +t 3 t 1 t 1 +s 91 s 92 +s 171 t 2 t 2 +s 175 s 176 +s 264 t 3 t 3 +s 286 s 287 +s 69

30. The specification of Trivium, cont. (s 1,s 2,...,s 93 ) (t 3,s 1,...,s 92 ) (s 94,s 95,...,s 177 ) (t 1,s 94,...,s 176 ) (s 178,s 179,...,s 288 ) (t 2,s 178,...,s 287 ) end for

31.ThecubeattackonTrivium Dinur and Shamir investigated the reduced version of Trivium which contains 672(instead of 1152) initialization rounds. During the preprocessing stage they obtained 63 linearly independent maxterms corresponding to 12-dimensional cubesandoutputbitsoftheindicesfrom672to685.

32. The cube attack on Trivium, cont. Intheonlinestagetheattackermustfindthevaluesof the maxterms summing over 63 12-dimensional cubes. After solving the system of linear equations the attacker obtains63bitsofthekeyandtheremaining17bitsof thekeyarefoundbybruteforcesearch. Thecomplexityoftheattack(intheonlinestage)isca. 2 19 evaluatioinsoftheinvestigated,reducedalgorithm.it issmallerthanthecomplexity2 55 inthepreviousattacks on this version of Trivium.

Cube attack Thank you