Fast Aes Decryption

Total Page:16

File Type:pdf, Size:1020Kb

Fast Aes Decryption FAST AES DECRYPTION Vinit Azad B.S., University of California, Davis, 2007 PROJECT Submitted in partial satisfaction of the requirements for the degree of MASTER OF SCIENCE in COMPUTER SCIENCE at CALIFORNIA STATE UNIVERSITY, SACRAMENTO SPRING 2011 FAST AES DECRYPTION A Project by Vinit Azad Approved by: __________________________________, Committee Chair Ted Krovetz, Ph.D. __________________________________, Second Reader Chung E. Wang, Ph.D. ____________________________ Date ii Student: Vinit Azad I certify that this student has met the requirements for format contained in the University format manual, and that this project is suitable for shelving in the Library and credit is to be awarded for the Project. __________________________, Graduate Coordinator ________________ Nikrouz Faroughi, Ph.D. Date Department of Computer Science iii Abstract of FAST AES DECRYPTION by Vinit Azad Due to the prevalent use of internet-enabled devices, confidentiality and privacy in communication has been more important than ever. Encryption algorithms, such as AES and RSA, are used to ensure the security and privacy of such communications. However, as computers get computationally powerful, more complex encryption algorithms are needed to avoid brute force attacks. This complexity in the algorithms also means that encryption and decryption of messages using these algorithms can be slow. To avoid this decrease in speed, many optimizations have been proposed to make these complex algorithms perform much faster. Emilia Käsper and Peter Schwabe proposed one such optimization to AES in their paper “Faster and Timing-Attack Resistant AES-GCM.” They describe a fast constant- time AES encryption algorithm, which is also immune from cache-timing attacks, using Intel’s SSE instructions. This paper focuses on the study of Käsper and Schwabe’s proposal and implements a fast constant-time AES decryption algorithm that can work with their encryption algorithm. The paper concludes that while the decryption algorithm is slower than the encryption algorithm proposed by Käsper and Schwabe, it is about 3 times faster than the standard decryption implementation such as OpenSSL. Therefore, this fast decryption algorithm paired with Käsper and Schwabe’s fast encryption iv algorithm can provide users a complete AES package that can be used in applications that require fast encryptions and decryption along with protection against timing attacks. _______________________, Committee Chair Ted Krovetz, Ph.D. _______________________ Date v TABLE OF CONTENTS Page List of Tables ................................................................................................................... viii List of Figures .................................................................................................................... ix Chapter 1. INTRODUCTION TO AES ........................................................................................... 1 1.1 AES State ........................................................................................................ 2 1.2 AES Encryption Algorithm............................................................................. 2 1.2.1 ShiftRows ......................................................................................... 3 1.2.2 MixColumns .................................................................................... 4 1.2.3 AddRoundKey ................................................................................. 4 1.2.4 SubBytes .......................................................................................... 5 1.3 AES Decryption Algorithm ............................................................................ 6 1.3.1 InvShiftRows ................................................................................... 8 1.3.2 InvMixColumns ............................................................................... 8 1.3.3 InvSubBytes ..................................................................................... 9 1.4 Key Expansion Algorithm .............................................................................. 9 2. BITSLICED AES ENCRYPTION .............................................................................. 12 2.1 Bitslicing ....................................................................................................... 13 2.2 Bitsliced ShiftRows ...................................................................................... 14 2.3 Bitsliced MixColumns .................................................................................. 14 2.4 Bitsliced AddRoundKey ............................................................................... 16 2.5 Bitsliced SubBytes ........................................................................................ 16 2.6 Bitsliced Key Expansion Algorithm ............................................................. 18 3. BITSLICED AES DECRYPTION .............................................................................. 19 3.1 Bitsliced InvShiftRows ................................................................................. 19 3.2 Bitsliced InvMixColumns ............................................................................. 20 3.3 Bitsliced AddRoundKey ............................................................................... 24 3.4 Bitsliced InvSubBytes ................................................................................... 25 vi 3.5 Bitsliced Inverse Key Expansion Algorithm ................................................ 26 4. VALIDATION AND PERFORMANCE ANALYSIS ................................................ 27 5. CONCLUSION ............................................................................................................ 30 Appendix A. Bitsliced Decryption Code ......................................................................... 33 Appendix B. OpenSSL Decryption Code ........................................................................ 60 Appendix C. System Configuration ................................................................................. 69 References ......................................................................................................................... 71 vii LIST OF TABLES Page 1. Table 4.1: Performance data for Core2Duo CPU ....................................................... 28 2. Table 4.2: Instruction count for AES operations ........................................................ 29 viii LIST OF FIGURES Page 1. Figure 1.1: Operation performed on State array ........................................................... 2 2. Figure 1.2: AES encryption psuedocode ..................................................................... 3 3. Figure 1.3: ShiftRows transformation .......................................................................... 4 4. Figure 1.4: Column multiplication ............................................................................... 4 5. Figure 1.5: AES decryption psuedocode ..................................................................... 7 6. Figure 1.6: InvShiftRows transformation .................................................................... 8 7. Figure 1.7: Inverse column multiplication .................................................................... 8 8. Figure 1.8: Key expansion algorithm.......................................................................... 10 9. Figure 2.1: Bitsliced 8 AES-State ............................................................................... 13 10. Figure 2.2: ShiftRows using pshufb............................................................................ 14 11. Figure 2.3: Equation for bitsliced MixColumns ......................................................... 15 12. Figure 2.4: Matrix used to change from standard basis to subfield basis ................... 17 13. Figure 2.5: Subfield basis to standard basis along with affine transformation ........... 18 14. Figure 3.1: InvShiftRows using pshufb ...................................................................... 20 15. Figure 3.2: Multiplication using shifts and XOR........................................................ 20 16. Figure 3.3: Shifts using XOR...................................................................................... 22 17. Figure 3.4: Galois multiplication using XORs ........................................................... 23 18. Figure 3.5: InvMixColumns equations ....................................................................... 24 19. Figure 3.6: Inverse affine transform and standard to subfield basis change ............... 25 20. Figure 3.7: Subfield to standard basis change matrix ................................................. 25 ix 1 Chapter 1 INTRODUCTION TO AES Due to prevalent use of internet-enabled devices, confidentiality and privacy in communication has been more important than ever. To provide this confidentiality for electronic communications, encryption algorithms are used [7]. There are two kinds of encryption algorithms: symmetric-key encryption and public-key encryption [7]. Symmetric encryption is also known as a single key encryption [7] because a single key is used for both encryption and decryption algorithm. Public-key encryption algorithm is an algorithm where a public key (available to all) and a separate private key (only known to one entity) are used for encryption and decryption [7]. Data Encryption Standard (DES), Advanced Encryption Standard (AES), Blowfish, and Serpent are all examples of symmetric
Recommended publications
  • Improved Correlation Attacks on SOSEMANUK and SOBER-128
    Improved Correlation Attacks on SOSEMANUK and SOBER-128 Joo Yeon Cho Helsinki University of Technology Department of Information and Computer Science, Espoo, Finland 24th March 2009 1 / 35 SOSEMANUK Attack Approximations SOBER-128 Outline SOSEMANUK Attack Method Searching Linear Approximations SOBER-128 2 / 35 SOSEMANUK Attack Approximations SOBER-128 SOSEMANUK (from Wiki) • A software-oriented stream cipher designed by Come Berbain, Olivier Billet, Anne Canteaut, Nicolas Courtois, Henri Gilbert, Louis Goubin, Aline Gouget, Louis Granboulan, Cedric` Lauradoux, Marine Minier, Thomas Pornin and Herve` Sibert. • One of the final four Profile 1 (software) ciphers selected for the eSTREAM Portfolio, along with HC-128, Rabbit, and Salsa20/12. • Influenced by the stream cipher SNOW and the block cipher Serpent. • The cipher key length can vary between 128 and 256 bits, but the guaranteed security is only 128 bits. • The name means ”snow snake” in the Cree Indian language because it depends both on SNOW and Serpent. 3 / 35 SOSEMANUK Attack Approximations SOBER-128 Overview 4 / 35 SOSEMANUK Attack Approximations SOBER-128 Structure 1. The states of LFSR : s0,..., s9 (320 bits) −1 st+10 = st+9 ⊕ α st+3 ⊕ αst, t ≥ 1 where α is a root of the primitive polynomial. 2. The Finite State Machine (FSM) : R1 and R2 R1t+1 = R2t ¢ (rtst+9 ⊕ st+2) R2t+1 = Trans(R1t) ft = (st+9 ¢ R1t) ⊕ R2t where rt denotes the least significant bit of R1t. F 3. The trans function Trans on 232 : 32 Trans(R1t) = (R1t × 0x54655307 mod 2 )≪7 4. The output of the FSM : (zt+3, zt+2, zt+1, zt)= Serpent1(ft+3, ft+2, ft+1, ft)⊕(st+3, st+2, st+1, st) 5 / 35 SOSEMANUK Attack Approximations SOBER-128 Previous Attacks • Authors state that ”No linear relation holds after applying Serpent1 and there are too many unknown bits...”.
    [Show full text]
  • A History of Syntax Isaac Quinn Dupont Facult
    Proceedings of the 2011 Great Lakes Connections Conference—Full Papers Email: A History of Syntax Isaac Quinn DuPont Faculty of Information University of Toronto [email protected] Abstract the arrangement of word tokens in an appropriate Email is important. Email has been and remains a (orderly) manner for processing by computers. Per- “killer app” for personal and corporate correspond- haps “computers” refers to syntactical processing, ence. To date, no academic or exhaustive history of making my definition circular. So be it, I will hide email exists, and likewise, very few authors have behind the engineer’s keystone of pragmatism. Email attempted to understand critical issues of email. This systems work (usually), because syntax is arranged paper explores the history of email syntax: from its such that messages can be passed. origins in time-sharing computers through Request This paper demonstrates the centrality of for Comments (RFCs) standardization. In this histori- syntax to the history of email, and investigates inter- cal capacity, this paper addresses several prevalent esting socio–technical issues that arise from the par- historical mistakes, but does not attempt an exhaus- ticular development of email syntax. Syntax is an tive historiography. Further, as part of the rejection important constraint for contemporary computers, of “mainstream” historiographical methodologies this perhaps even a definitional quality. Additionally, as paper explores a critical theory of email syntax. It is machines, computers are physically constructed. argued that the ontology of email syntax is material, Thus, email syntax is material. This is a radical view but contingent and obligatory—and in a techno– for the academy, but (I believe), unproblematic for social assemblage.
    [Show full text]
  • On Distinguishing Attack Against the Reduced Version of the Cipher Nlsv2
    Ø Ñ ÅØÑØÐ ÈÙ ÐØÓÒ× DOI: 10.2478/v10127-012-0037-5 Tatra Mt. Math. Publ. 53 (2012), 21–32 ON DISTINGUISHING ATTACK AGAINST THE REDUCED VERSION OF THE CIPHER NLSV2 Michal Braˇsko — Jaroslav Boor ABSTRACT. The Australian stream cipher NLSv2 [Hawkes, P.—Paddon, M.– –Rose, G. G.—De Vries, M. W.: Primitive specification for NLSv2, Project eSTREAM web page, 2007, 1–25] is a 32-bit word oriented stream cipher that was quite successful in the stream ciphers competition—the project eSTREAM. The cipher achieved Phase 3 and successfully accomplished one of the main require- ments for candidates in Profile 1 (software oriented proposals)—to have a better performance than AES in counter mode. However the cipher was not chosen into the final portfolio [Babbage, S.–De Canni`ere, Ch.–Canteaut, A.–Cid, C.– –Gilbert, H.–Johansson, T.–Parker, M.–Preneel, B.–Rijmen, V.–Robshaw, M.: The eSTREAM Portfolio, Project eSTREAM web page, 2008], because its per- formance was not so perfect when comparing with other finalist. Also there is a security issue with a high correlation in the used S-Box, which some effective distinguishers exploit. In this paper, a practical demonstration of the distinguish- ing attack against the smaller version of the cipher is introduced. In our experi- ments, we have at disposal a machine with four cores (IntelR CoreTM Quad @ 2.66 GHz) and single attack lasts about 6 days. We performed successful practi- cal experiments and our results demonstrate that the distingushing attack against the smaller version is working. 1. Introduction The cipher NLSv2 is a synchronous, word-oriented stream cipher developed by Australian researchers P h i l i p H a w k e s, C a m e r o n M c D o n a l d, M i - chael Paddon,Gregory G.Rose andMiriam Wiggers de Vreis in 2007 [6].
    [Show full text]
  • SAC 2006 Preliminary Program Wednesday August 16, 2006
    SAC 2006 Preliminary Program All events, except the Banquet, are held at the EV building (1515 St. Catherine W.) All the presentations will be held at EV2.260 The Wednesday reception will be held at EV2.184 The board meeting (open only to board members) will be held at EV9.221 Wednesday August 16, 2006 18:30-20:00 Light social reception (EV2.184) Thursday August 17, 2006 08:00 Registration and Morning Coffee 08:50-09:00 Welcome Remarks Block Cipher Cryptanalysis Chair: Bart Preneel 09:25-09:50 Improved DST Cryptanalysis of IDEA Eyup Serdar Ayaz, Ali Aydin Selcuk 09:50-10:15 Improved Related-Key Impossible Differential Attacks on Reduced-Round AES-192 Wentao Zhang, Wenling Wu, Lei Zhang, Dengguo Feng 09:00-09:25 Related-Key Rectangle Attack on the Full SHACAL-1 Orr Dunkelman, Nathan Keller, Jongsung Kim 10:15-10:45 Coffee Break Stream Cipher Cryptanalysis I Chair: Helena Handschuh 10:45-11:10 Cryptanalysis of Achterbahn-Version 2 Martin Hell, Thomas Johansson 11:10-11:35 Cryptanalysis of the Stream Cipher ABC v2 Hongjun Wu, Bart Preneel Invited Talk I: The Stafford Tavares Lecture Chair: Eli Biham 11:35-12:30 A Top View of Side Channels Adi Shamir 12:30-14:00 Lunch (EV2.184) Block and Stream Ciphers Chair: Orr Dunkelman 14:00-14:25 The Design of a Stream Cipher Lex Alex Biryukov 14:25-14:50 Dial C for Cipher Thomas Baignères, Matthieu Finiasz 14:50-15:15 Tweakable Block Cipher Revisited Kazuhiko Minematsu 15:15-15:45 Coffee Break Side-Channel Attacks Chair: Carlisle Adams 15:45-16:10 Extended Hidden Number Problem and its Cryptanalytic
    [Show full text]
  • Rocket Universe NLS Guide
    Rocket UniVerse NLS User Guide Version 12.1.1 June 2019 UNV-1211-NLS-1 Notices Edition Publication date: June 2019 Book number: UNV-1211-NLS-1 Product version: Version 12.1.1 Copyright © Rocket Software, Inc. or its affiliates 1985–2019. All Rights Reserved. Trademarks Rocket is a registered trademark of Rocket Software, Inc. For a list of Rocket registered trademarks go to: www.rocketsoftware.com/about/legal. All other products or services mentioned in this document may be covered by the trademarks, service marks, or product names of their respective owners. Examples This information might contain examples of data and reports. The examples include the names of individuals, companies, brands, and products. All of these names are fictitious and any similarity to the names and addresses used by an actual business enterprise is entirely coincidental. License agreement This software and the associated documentation are proprietary and confidential to Rocket Software, Inc. or its affiliates, are furnished under license, and may be used and copied only in accordance with the terms of such license. Note: This product may contain encryption technology. Many countries prohibit or restrict the use, import, or export of encryption technologies, and current use, import, and export regulations should be followed when exporting this product. 2 Corporate information Rocket Software, Inc. develops enterprise infrastructure products in four key areas: storage, networks, and compliance; database servers and tools; business information and analytics; and application development, integration, and modernization. Website: www.rocketsoftware.com Rocket Global Headquarters 77 4th Avenue, Suite 100 Waltham, MA 02451-1468 USA To contact Rocket Software by telephone for any reason, including obtaining pre-sales information and technical support, use one of the following telephone numbers.
    [Show full text]
  • (12) United States Patent (10) Patent No.: US 6,226,618 B1 Downs Et Al
    USOO62266 18B1 (12) United States Patent (10) Patent No.: US 6,226,618 B1 DOWns et al. (45) Date of Patent: May 1, 2001 (54) ELECTRONIC CONTENT DELIVERY 4,782,529 11/1988 Shima. SYSTEM 4,803,725 2/1989 Horne et al. 4,809,327 2/1989 Shima. (75) Inventors: Edgar Downs, Fort Lauderdale; 4,825,306 4/1989 Robers. George Gregory Gruse, Lighthouse 4,868,687 9/1989 Penn et al.. Point; Marco M. Hurtado, Boca (List continued on next page.) Raton; Christopher T. Lehman, Delray Beach; Kenneth Louis Milsted, OTHER PUBLICATIONS Boynton Beach, all of FL (US); Jeffrey J. Linn, “Privacy Enhancement for Internet Electronic Mail: B. Lotspiech, San Jose, CA (US) Part I: Message Encryption and Authentication Procedures”, RFC 1421, Feb., 1993, pp. 1–37. (73) Assignee: International Business Machines S. Kent, “Privacy Enhancement or Internet Electronic Mail: Corporation, Armonk, NY (US) Part II: Certificate-Based Key Management'. RFC 1422, Feb., 1993, pp. 1-28. (*) Notice: Subject to any disclaimer, the term of this D. Balenson, “Privace Enhancement for Internet Mail: Part patent is extended or adjusted under 35 III: Algorithms, Modes, and Indentifiers", RFC 1423, Feb. U.S.C. 154(b) by 0 days. 1993, pp. 1-13. B. Kaliski, “Privacy Enhancement for Internet Electronic (21) Appl. No.: 09/133,519 Mail: Part IV: Key Certification and Related Services", RFC 1424, Feb. 1993, pp. 1-8. (22) Filed: Aug. 13, 1998 sk cited- by examiner (51) Int. Cl." .................................................... H04L 9/00 Primary Examiner James P. Trammell Assistant Examiner Nga B. Nguyen (52) U.S. Cl.
    [Show full text]
  • Crossword Puzzle Attack on NLS
    Crossword Puzzle Attack on NLS Joo Yeon Cho and Josef Pieprzyk Centre for Advanced Computing – Algorithms and Cryptography, Department of Computing, Macquarie University, NSW, Australia, 2109 {jcho,josef}@ics.mq.edu.au Abstract. NLS is one of the stream ciphers submitted to the eSTREAM project. We present a distinguishing attack on NLS by Crossword Puzzle (CP) attack method which is newly introduced in this paper. We build the distinguisher by using linear approximations of both the non-linear feedback shift register (NFSR) and the non- linear filter function (NLF). Since the bias of the distinguisher depends on the Konst value, which is a key-dependent word, we present the graph showing how the bias of distinguisher vary with Konst. In result, we estimate the average bias to be around − O(2 30). Therefore, we claim that NLS is distinguishable from truly random cipher after observing O(260) keystream words on the average. The experiments also show that our distinguishing attack is successful on 90.3% of Konst among 232 possible values. Keywords : Distinguishing Attacks, Stream Ciphers, Linear Approximations, eS- TREAM, Modular Addition, NLS. 1 Introduction The European Network of Excellence in Cryptology (ECRYPT) launched a stream cipher project called eSTREAM [1] whose aim is to come up with a collection of stream ciphers that can be recommended to industry and government institutions as secure and efficient cryptographic primitives. It is also likely that some or perhaps all recommended stream ciphers may be considered as de facto industry standards. It is interesting to see a variety of different approaches used by the designers of the stream ciphers submitted to the eSTREAM call.
    [Show full text]
  • CAST-256 Algorithm Specification
    CAST-256 Algorithm Specification 1. Algorithm Specification 1.1 CAST-128 Notation The following notation from CAST-128 [A97b, A97c] is relevant to CAST-256. • CAST-128 uses a pair of subkeys per round: a 5-bit quantity k is used as a ri “rotation” key for round i and a 32-bit quantity k is used as a “masking” key for mi round i. • Three different round functions are used in CAST-128. The rounds are as follows (where D is the data input to the operation, I a - I d are the most significant byte th through least significant byte of I , respectively, Si is the i s-box (see following page for s-box definitions), and O is the output of the operation). Note that + and - are addition and subtraction modulo 232 , ⊕ is bitwise eXclusive-OR, and ↵ is the circular left-shift operation. Type 1: I = ((k + D) ↵ k ) mi ri = ⊕ − + O ((S1[I a ] S2 [Ib ]) S3[I c ]) S4 [I d ] Type 2: I = ((k ⊕ D) ↵ k ) mi ri = − + ⊕ O ((S1[I a ] S2 [Ib ]) S3[I c ]) S4 [I d ] Type 3: I = ((k − D) ↵ k ) mi ri = + ⊕ − O ((S1[I a ] S2 [Ib ]) S3[I c ]) S4 [I d ] Let f1 , f 2 , f 3 be keyed round function operations of Types 1, 2, and 3 (respectively) above. CAST-128 Notation (cont’d) • CAST-128 uses four round function substitution boxes (s-boxes), S1 - S4 . These are defined as follows (entries (written in hexadecimal notation) are to be read left-to- right, top-to-bottom).
    [Show full text]
  • Software Speed of Stream Ciphers
    Software speed of stream ciphers Daniel J. Bernstein1 and Tanja Lange2 1 Department of Computer Science University of Illinois at Chicago, Chicago, IL 60607{7045, USA [email protected] 2 Department of Mathematics and Computer Science Technische Universiteit Eindhoven, P.O. Box 513, 5600 MB Eindhoven, Netherlands [email protected] When eSTREAM came to an end in 2008, did stream-cipher benchmarking also come to an end? No! Here's a graph of stream-cipher performance on a computer named h1mx515, a freshly purchased pocket-size Sharp Netwalker: This computer has a Freescale i.MX515 CPU released in 2009. The core of this CPU is an ARM Cortex A8, the same ARMv7-A core used in the Apple A4 (iPad, iPhone 4). The horizontal axis on the graph is message length, from 0 bytes to 2000 bytes; the vertical axis is time, from 0 cycles to 20000 cycles; the bottom-left-to-top-right diagonal is 10 cycles/byte. This graph can be found on the web pages of the eBASC project run by ECRYPT's VAMPIRE lab, along with 131 graphs for other machines with a wide variety of CPUs. ABIs include amd64, armeabi, cellspu, ia64, mips32, mips64, mipso32, ppc32, ppc64, sparcv9, and x86; if a machine supports two ABIs then it is graphed separately for each ABI. Each graph is clickable for higher resolution, and is accompanied by several tables showing median cycle counts and quartile cycle counts for various message lengths. Implementors can click on machine names to see comparisons of the performance of different implementations of the same cipher (rather than just the best implementation, the one whose perfor- mance is graphed), and to see compiler errors and test errors for non-functional implementations.
    [Show full text]
  • Rocket Universe NLS Guide
    Rocket UniVerse NLS Guide Version 11.2 November 2013 UNV-112-NLS-1 Notices Edition Publication date: November 2013 Book number: UNV-112-NLS-1 Product version: Rocket UniVerse V11.2 Copyright © Rocket Software, Inc. or its affiliates 1985-2014. All Rights Reserved. Trademarks Rocket is a registered trademark of Rocket Software, Inc. For a list of Rocket registered trademarks go to: www.rocketsoftware.com/about/legal. All other products or services mentioned in this document may be covered by the trademarks, service marks, or product names of their respective owners. Examples This information might contain examples of data and reports. The examples include the names of individuals, companies, brands, and products. All of these names are fictitious and any similarity to the names and addresses used by an actual business enterprise is entirely coincidental. License agreement This software and the associated documentation are proprietary and confidential to Rocket Software, Inc., are furnished under license, and may be used and copied only in accordance with the terms of such license. Note: This product may contain encryption technology. Many countries prohibit or restrict the use, import, or export of encryption technologies, and current use, import, and export regulations should be followed when exporting this product. Contact information Website: www.rocketsoftware.com Rocket Software, Inc. Headquarters 77 4th Avenue, Suite 100 Waltham, MA 02451-1468 USA Tel: +1 781 577 4321 Fax: +1 617 630 7100 2 Contacting Global Technical Support If you have current support and maintenance agreements with Rocket Software, you can access the Rocket Customer Portal to report and track a problem, to submit an enhancement request or question, or to find answers in the U2 Knowledgebase.
    [Show full text]
  • Security of Cryptographic Tasks
    Studies in the Efficiency and (versus) Security of Cryptographic Tasks Mohammad Mahmoody-Ghidary A Dissertation Presented to the Faculty of Princeton University in Candidacy for the Degree of Doctor of Philosophy Recommended for Acceptance by the Department of Computer Science Advisers: Boaz Barak September 2010 c Copyright by Mohammad Mahmoody-Ghidary, 2010. All Rights Reserved Abstract In this thesis, we deal with the following questions: (1) How efficient a cryptographic algo- rithm can be while achieving a desired level of security? (2) Since mathematical conjectures like P 6= NP are necessary for the possibility of secure cryptographic primitives in the standard models of computation: (a) Can we base cryptography solely based on the widely believed assumption of P 6= NP, or do we need stronger assumptions? (b) Which alternative nonstandard models offer us provable security unconditionally, while being implementable in real life? First we study the question of security vs. efficiency in public-key cryptography and prove tight bounds on the efficiency of black-box constructions of key-agreement and (public-key) digital signatures that achieve a desired level of security using \random-like" functions. Namely, we prove that any key-agreement protocol in the random oracle model where the parties ask at most n oracle queries can be broken by an adversary who asks at most O(n2) oracle queries and finds the key with high probability. This improves upon the previous Oe(n6)-query attack of Impagliazzo and Rudich [98] and proves that a simple key-agreement protocol due to Merkle [118] is optimal. We also prove that any signature scheme in the random oracle model where the parties ask at most q oracle queries can be broken by an adversary who forges a signature by asking at most 2O(q) oracle queries.
    [Show full text]
  • A Practical Distinguisher for the Shannon Cipher Q
    The Journal of Systems and Software 83 (2010) 543–547 Contents lists available at ScienceDirect The Journal of Systems and Software journal homepage: www.elsevier.com/locate/jss A practical distinguisher for the Shannon cipher q Zahra Ahmadian a,*, Javad Mohajeri b, Mahmoud Salmasizadeh b, Risto M. Hakala c, Kaisa Nyberg c a Department of Electrical Engineering, Sharif University of Technology, Tehran, Iran b Electronics Research Center, Sharif University of Technology, Tehran, Iran c Department of Information and Computer Science, Helsinki University of Technology, Finland article info abstract Article history: In this paper, we present a practical linear distinguisher on the Shannon stream cipher. Shannon is a syn- Received 29 November 2008 chronous stream cipher that uses at most 256-bit secret key. In the specification for Shannon, designers Received in revised form 29 August 2009 state that the intention of the design is to make sure that there are no distinguishing attacks on Shannon Accepted 13 October 2009 requiring less than 280 keystream words and less than 2128 computations. In this work we use the Cross- Available online 28 October 2009 word Puzzle attack technique to construct a distinguisher which requires a keystream of length about 231 words with workload about 231. Keywords: Ó 2009 Elsevier Inc. All rights reserved. Stream ciphers Shannon Distinguishing attack Crossword Puzzle attack Linear cryptanalysis 1. Introduction Linear distinguishing attacks have been presented to numbers of stream ciphers such as SNOW 1.0 (Coppersmith et al., 2002), SNOW Stream ciphers form an important class of symmetric encryp- 2.0 (Watanabe et al., 2004; Nyberg and Wallen, 2006), SOBER-128 tion primitives.
    [Show full text]