Stream Cipher Universal Hash Pseudorandom Function

Total Page:16

File Type:pdf, Size:1020Kb

Stream Cipher Universal Hash Pseudorandom Function SCU-PRF CONSTRUCTING A SECURE CHANNEL USING A PSEUDORANDOM FUNCTION A Thesis Presented to the faculty of the Department of Computer Science California State University, Sacramento Submitted in partial satisfaction of the requirements for the degree MASTER OF SCIENCE in Computer Science by Matthew Clarke-Lauer SPRING 2012 SCU-PRF CONSTRUCTING A SECURE CHANNEL USING A PSEUDORANDOM FUNCTION A Thesis by Matthew Clarke-Lauer Approved by: , Committee Chair Dr. Theodore Krovetz , Second Reader Dr. V. Scott Gordon , Third Reader Dr. Jinsong Ouyang Date ii Student: Matthew Clarke-Lauer I certify that this student has met the requirements for format contained in the University format manual, and that this thesis is suitable for shelving in the Library and credit is to be awarded for the thesis. , Department Chair Dr. Cui Zhang Date Department of Computer Science iii Abstract of SCU-PRF CONSTRUCTING A SECURE CHANNEL USING A PSEUDORANDOM FUNCTION by Matthew D. Clarke-Lauer The establishment of a secure channel of communication between two parties is a primary goal of modern cryptography. In an ideal world, the secure channel is a dedicated, untappable, and impenetrable method of transmitting data between a sender and receiver. An adversary would be unable to see or modify any information crossing the channel. Unfortunately, that is not possible in the real world. Most communication is done using channels that are susceptible to eavesdropping and in- terference. In order to overcome these problem cryptography attempts to recreate the secure channel in order to provide confidentiality and authenticity to all com- munications between two parties. Pseudorandom functions provide an ideal starting point for designing cryptographic primitives that met these goals. Work done by Philip Rogaway and Mihir Bellare has shown the usefulness of a random oracle as a starting point for developing asymmetric-key cryptographic primitives. This paper expands on that concept by providing algorithms that meet the goals of confidentiality and authenticity by using a conceptual pseudorandom function to construct a set of symmetric-key cryptographic primitives. Due to it's flexibility and simplicity, a conceptual pseudorandom function is used to construct a iv symmetric-key cipher and a message authentication code that are both simple and efficient, while meeting the requirements of a confidentiality and authenticity. Based on those two primitives, an authenticated encryption scheme is built in order to provide the guarantees of the secure channel. This paper provides the design and implementation for the SCU-PRF, a pseu- dorandom function created by combining the Salsa20 stream cipher and the VHASH universal hash function. The SCU-PRF is designed with the goal of efficiency, re- quiring little more computation than the base components of Salsa20 and VHASH. Using the algorithms built with the conceptual PRF, a complete implementation of the protocols is created using SCU-PRF. When tested SCU-PRF proved to be an efficient and flexible pseudorandom function with a performance profile ideal for constructing a high efficiency secure channel. , Committee Chair Dr. Theodore Krovetz Date v DEDICATION This work is dedicated to my wife Annie and my son Eli. Thank you for providing me a reason to always strive for better vi ACKNOWLEDGMENT I would like to thank my advisor, Dr. Ted Krovetz, for his time and encour- agement in finishing this Master's thesis. Without his guidance this thesis would not have been possible. vii TABLE OF CONTENTS Page Dedication . vi Acknowledgement . vii List of Tables . xi List of Figures . xii Chapter 1. INTRODUCTION . 1 2. PSEUDORANDOM FUNCTIONS AND THEIR MATHEMATICAL BACK- GROUND . 4 2.1. Adversarial Models . 4 2.2. Mathematical Background . 5 2.2.1. Functions . 5 2.2.2. Randomness . 6 2.2.3. Pseudorandomness . 7 2.3. Related Work . 8 3. OVERVIEW OF THE SECURE CHANNEL . 10 3.1. Trust Models . 10 3.2. Privacy . 11 3.2.1. Block Cipher . 11 3.2.2. Stream Cipher . 12 3.3. Authenticity . 14 3.3.1. Message Authentication Code . 15 viii 3.3.2. Universal Hash-Functions Family . 16 4. CONSTRUCTING THE SECURE CHANNEL WITH PSEUDORANDOM FUNCTIONS . 18 4.1. Conceptual Pseudorandom Function . 18 4.2. Confidentiality Using a PRF . 18 4.3. Authentication Using a PRF . 20 4.4. Constructing the Secure Channel . 21 5. SCU-PRF - STREAM CIPHER UNIVERSAL HASH PSEUDORANDOM FUNCTION . 23 5.1. Test Environment . 23 5.2. Phase 1 - Compression . 23 5.2.1. VHASH . 24 5.2.2. Probability of Hash Collisions . 25 5.3. Phase 2 - Expansion . 27 5.3.1. Salsa20 . 27 5.4. Engineering Obstacles . 29 5.4.1. Key Handling . 29 5.4.2. VHASH Modifications . 29 5.4.3. Salsa20 Modifications . 29 5.4.4. SCU-PRF Context . 30 5.5. SCU-PRF Algorithm . 30 5.5.1. SCU-PRF Performance . 30 5.6. Cryptographic Applications and Performance . 31 5.6.1. Encryption . 31 ix 5.6.2. Authentication . 33 5.6.3. Secure Channel Performance . 37 5.7. Performance Overview . 39 6. CONCLUSION . 41 6.1. Future Work . 42 Appendix . Source Code . 44 References . 54 x LIST OF TABLES Page Table 5.1. Specifications of Lenovo T400 Test Platform . 24 Table 5.2. Performance of VHASH-128 in CPU Cycles Per Block . 25 Table 5.3. Performance of SCU-PRF in CPU Cycles Per Byte . 32 Table 5.4. Performance of SCU-PRF Based Encryption in CPU Cycles Per Byte . 34 Table 5.5. Performance of SCU-PRF Based Authentication in CPU Cycles Per Byte . 36 Table 5.6. Performance of SCU-PRF Based Authenticated Encryption in CPU Cycles Per Byte . 38 Table 5.7. Cryptographic Algorithm Performance Comparison . 40 xi LIST OF FIGURES Page Figure 3.1. Encryption Data Flow . 12 Figure 3.2. Message Authentication Data Flow . 15 Figure 3.3. Message Authentication Code Data Flow . 16 Figure 5.1. SCU-PRF Design . 28 Figure 5.2. SCU-PRF Efficiency . 33 Figure 5.3. SCU-PRF Based Encryption Efficiency . 35 Figure 5.4. SCU-PRF Based MAC Efficiency . 35 Figure 5.5. SCU-PRF Based Authenticate Encryption Efficiency . 37 xii 1 CHAPTER 1 INTRODUCTION As technology has advanced, so has the act of communication. Exchanging information in a secure fashion has changed with the advent of digital communica- tions and the internet. As society moves away from a physical and analog world, the methods used for providing privacy have changed. Digital eavesdropping has become more prevalent due to the flow of information around the globe. A message can be modified and transmitted in a fraction of a second by an adversary with simple and affordable tools. Due to these changes, the difficulty of providing confidentiality and authenticity has grown. Cryptography is the study of techniques for providing information security. It uses mathematical systems to establish a secure channel for communications. In order to provide a secure channel, two major goals must be achieved: confidentiality and authenticity. To achieve these goals, a number of different tools or cryptographic primitives are utilized, many of which have their foundations in the ability to produce random data. The goal of confidentiality is to prevent an unauthorized party from access- ing secret information. This could be as simple as preventing a third party from reading an email between family members or as complex as protecting a database of private consumer information. Encryption schemes are used to achieve confiden- tial communication. They provide a party with the ability to disguise or encrypt a message. For example, substitution cipher requires letters of the original message to be substituted for other letters of the alphabet. This is a very rudimentary cipher 2 and was historically performed by hand using a shared key, a piece of shared private information. The cipher is used to encode a message, or plain text, into its secret equivalent, or cipher text. In the case of the substitution cipher, the key was just a list of the letters in the alphabet along with the letters they are mapped to. Once the encrypted message was received, the same key would be used to reverse the encryp- tion, providing the receiver with the original message. While the use of this style of cipher is now obsolete, the concept of using a shared private key to encode plain text messages into the cipher text equivalent is the basis for all modern encryption.[4] The goal of authenticity is two fold. Message authenticity is the concept of determining whether a message was modified. On the other hand, user authenticity provides a guarantee about the identity of the sender of a message. Unless the receiver physically observes the sender creating the message, the source of a message and the message's authenticity is unknown to a receiver. Cryptography has solved this problem by creating a message authentications code(MAC). The sender can use the shared private-key, like the cipher example above, to create a signature or fingerprint that represents the message using the MAC. The signature or fingerprint is a condensed representation of the message that is not easily recreated and serves as proof that the message came from the sender. The receiver can create their own signature based on the message and if the two are the same then the message must be unmodified and must have come from the sender or a party with the same private key.[4] Within cryptography, the concept of randomness, or statistically unrelated data[16], is used to achieve the goals of confidentiality and authenticity. Unfor- tunately, true randomness is very difficult to achieve with modern computers. Due to the fact the computers are deterministic machines, pseudorandomness is used in- 3 stead. Pseudorandom data is generated deterministically from non-random sources and should be computationally indistinguishable from true randomness.[1] This al- lows cryptographic primitives to be built using a reproducible source of data that appears to be random.
Recommended publications
  • Breaking Crypto Without Keys: Analyzing Data in Web Applications Chris Eng
    Breaking Crypto Without Keys: Analyzing Data in Web Applications Chris Eng 1 Introduction – Chris Eng _ Director of Security Services, Veracode _ Former occupations . 2000-2006: Senior Consulting Services Technical Lead with Symantec Professional Services (@stake up until October 2004) . 1998-2000: US Department of Defense _ Primary areas of expertise . Web Application Penetration Testing . Network Penetration Testing . Product (COTS) Penetration Testing . Exploit Development (well, a long time ago...) _ Lead developer for @stake’s now-extinct WebProxy tool 2 Assumptions _ This talk is aimed primarily at penetration testers but should also be useful for developers to understand how your application might be vulnerable _ Assumes basic understanding of cryptographic terms but requires no understanding of the underlying math, etc. 3 Agenda 1 Problem Statement 2 Crypto Refresher 3 Analysis Techniques 4 Case Studies 5 Q & A 4 Problem Statement 5 Problem Statement _ What do you do when you encounter unknown data in web applications? . Cookies . Hidden fields . GET/POST parameters _ How can you tell if something is encrypted or trivially encoded? _ How much do I really have to know about cryptography in order to exploit implementation weaknesses? 6 Goals _ Understand some basic techniques for analyzing and breaking down unknown data _ Understand and recognize characteristics of bad crypto implementations _ Apply techniques to real-world penetration tests 7 Crypto Refresher 8 Types of Ciphers _ Block Cipher . Operates on fixed-length groups of bits, called blocks . Block sizes vary depending on the algorithm (most algorithms support several different block sizes) . Several different modes of operation for encrypting messages longer than the basic block size .
    [Show full text]
  • Key Differentiation Attacks on Stream Ciphers
    Key differentiation attacks on stream ciphers Abstract In this paper the applicability of differential cryptanalytic tool to stream ciphers is elaborated using the algebraic representation similar to early Shannon’s postulates regarding the concept of confusion. In 2007, Biham and Dunkelman [3] have formally introduced the concept of differential cryptanalysis in stream ciphers by addressing the three different scenarios of interest. Here we mainly consider the first scenario where the key difference and/or IV difference influence the internal state of the cipher (∆key, ∆IV ) → ∆S. We then show that under certain circumstances a chosen IV attack may be transformed in the key chosen attack. That is, whenever at some stage of the key/IV setup algorithm (KSA) we may identify linear relations between some subset of key and IV bits, and these key variables only appear through these linear relations, then using the differentiation of internal state variables (through chosen IV scenario of attack) we are able to eliminate the presence of corresponding key variables. The method leads to an attack whose complexity is beyond the exhaustive search, whenever the cipher admits exact algebraic description of internal state variables and the keystream computation is not complex. A successful application is especially noted in the context of stream ciphers whose keystream bits evolve relatively slow as a function of secret state bits. A modification of the attack can be applied to the TRIVIUM stream cipher [8], in this case 12 linear relations could be identified but at the same time the same 12 key variables appear in another part of state register.
    [Show full text]
  • Stream Ciphers (Contd.)
    Stream Ciphers (contd.) Debdeep Mukhopadhyay Assistant Professor Department of Computer Science and Engineering Indian Institute of Technology Kharagpur INDIA -721302 Objectives • Non-linear feedback shift registers • Stream ciphers using LFSRs: – Non-linear combination generators – Non-linear filter generators – Clock controlled generators – Other Stream Ciphers Low Power Ajit Pal IIT Kharagpur 1 Non-linear feedback shift registers • A Feedback Shift Register (FSR) is non-singular iff for all possible initial states every output sequence of the FSR is periodic. de Bruijn Sequence An FSR with feedback function fs(jj−−12 , s ,..., s jL − ) is non-singular iff f is of the form: fs=⊕jL−−−−+ gss( j12 , j ,..., s jL 1 ) for some Boolean function g. The period of a non-singular FSR with length L is at most 2L . If the period of the output sequence for any initial state of a non-singular FSR of length L is 2L , then the FSR is called a de Bruijn FSR, and the output sequence is called a de Bruijn sequence. Low Power Ajit Pal IIT Kharagpur 2 Example f (,xxx123 , )1= ⊕⊕⊕ x 2 x 3 xx 12 t x1 x2 x3 t x1 x2 x3 0 0 0 0 4 0 1 1 1 1 0 0 5 1 0 1 2 1 1 0 6 0 1 0 3 1 1 1 3 0 0 1 Converting a maximal length LFSR to a de-Bruijn FSR Let R1 be a maximum length LFSR of length L with linear feedback function: fs(jj−−12 , s ,..., s jL − ). Then the FSR R2 with feedback function: gs(jj−−12 , s ,..., s jL − )=⊕ f sjj−−12 , s ,..., s j −L+1 is a de Bruijn FSR.
    [Show full text]
  • An Analysis of the Hermes8 Stream Ciphers
    An Analysis of the Hermes8 Stream Ciphers Steve Babbage1, Carlos Cid2, Norbert Pramstaller3,andH˚avard Raddum4 1 Vodafone Group R&D, Newbury, United Kingdom [email protected] 2 Information Security Group, Royal Holloway, University of London Egham, United Kingdom [email protected] 3 IAIK, Graz University of Technology Graz, Austria [email protected] 4 Dept. of Informatics, The University of Bergen, Bergen, Norway [email protected] Abstract. Hermes8 [6,7] is one of the stream ciphers submitted to the ECRYPT Stream Cipher Project (eSTREAM [3]). In this paper we present an analysis of the Hermes8 stream ciphers. In particular, we show an attack on the latest version of the cipher (Hermes8F), which requires very few known keystream bytes and recovers the cipher secret key in less than a second on a normal PC. Furthermore, we make some remarks on the cipher’s key schedule and discuss some properties of ci- phers with similar algebraic structure to Hermes8. Keywords: Hermes8, Stream Cipher, Cryptanalysis. 1 Introduction Hermes8 is one of the 34 stream ciphers submitted to eSTREAM, the ECRYPT Stream Cipher Project [3]. The cipher has a simple byte-oriented design, con- sisting of substitutions and shifts of the state register bytes. Two versions of the cipher have been proposed. Originally, the cipher Hermes8 [6] was submitted as candidate to eSTREAM. Although no weaknesses of Hermes8 were found dur- ing the first phase of evaluation, the cipher did not seem to present satisfactory performance in either software or hardware [4]. As a result, a slightly modified version of the cipher, named Hermes8F [7], was submitted for consideration dur- ing the second phase of eSTREAM.
    [Show full text]
  • Cs 255 (Introduction to Cryptography)
    CS 255 (INTRODUCTION TO CRYPTOGRAPHY) DAVID WU Abstract. Notes taken in Professor Boneh’s Introduction to Cryptography course (CS 255) in Winter, 2012. There may be errors! Be warned! Contents 1. 1/11: Introduction and Stream Ciphers 2 1.1. Introduction 2 1.2. History of Cryptography 3 1.3. Stream Ciphers 4 1.4. Pseudorandom Generators (PRGs) 5 1.5. Attacks on Stream Ciphers and OTP 6 1.6. Stream Ciphers in Practice 6 2. 1/18: PRGs and Semantic Security 7 2.1. Secure PRGs 7 2.2. Semantic Security 8 2.3. Generating Random Bits in Practice 9 2.4. Block Ciphers 9 3. 1/23: Block Ciphers 9 3.1. Pseudorandom Functions (PRF) 9 3.2. Data Encryption Standard (DES) 10 3.3. Advanced Encryption Standard (AES) 12 3.4. Exhaustive Search Attacks 12 3.5. More Attacks on Block Ciphers 13 3.6. Block Cipher Modes of Operation 13 4. 1/25: Message Integrity 15 4.1. Message Integrity 15 5. 1/27: Proofs in Cryptography 17 5.1. Time/Space Tradeoff 17 5.2. Proofs in Cryptography 17 6. 1/30: MAC Functions 18 6.1. Message Integrity 18 6.2. MAC Padding 18 6.3. Parallel MAC (PMAC) 19 6.4. One-time MAC 20 6.5. Collision Resistance 21 7. 2/1: Collision Resistance 21 7.1. Collision Resistant Hash Functions 21 7.2. Construction of Collision Resistant Hash Functions 22 7.3. Provably Secure Compression Functions 23 8. 2/6: HMAC And Timing Attacks 23 8.1. HMAC 23 8.2.
    [Show full text]
  • A 32-Bit RC4-Like Keystream Generator
    A 32-bit RC4-like Keystream Generator Yassir Nawaz1, Kishan Chand Gupta2 and Guang Gong1 1Department of Electrical and Computer Engineering University of Waterloo Waterloo, ON, N2L 3G1, CANADA 2Centre for Applied Cryptographic Research University of Waterloo Waterloo, ON, N2L 3G1, CANADA [email protected], [email protected], [email protected] Abstract. In this paper we propose a new 32-bit RC4 like keystream generator. The proposed generator produces 32 bits in each iteration and can be implemented in software with reasonable memory requirements. Our experiments show that this generator is 3.2 times faster than original 8-bit RC4. It has a huge internal state and offers higher resistance against state recovery attacks than the original 8-bit RC4. We analyze the ran- domness properties of the generator using a probabilistic approach. The generator is suitable for high speed software encryption. Keywords: RC4, stream ciphers, random shuffle, keystream generator. 1 Introduction RC4 was designed by Ron Rivest in 1987 and kept as a trade secret until it leaked in 1994. In the open literatures, there is very small number of proposed keystream generator that are not based on shift registers. An interesting design approach of RC4 which have originated from exchange- shuffle paradigm [10], is to use a relatively big table/array that slowly changes with time under the control of itself. As discussed by Goli´c in [5], for such a generator a few general statistical properties of the keystream can be measured by statistical tests and these criteria are hard to establish theoretically.
    [Show full text]
  • Iso/Iec 18033-4:2005(E)
    This preview is downloaded from www.sis.se. Buy the entire standard via https://www.sis.se/std-906455 INTERNATIONAL ISO/IEC STANDARD 18033-4 First edition 2005-07-15 Information technology — Security techniques — Encryption algorithms — Part 4: Stream ciphers Technologies de l'information — Techniques de sécurité — Algorithmes de chiffrement — Partie 4: Chiffrements en flot Reference number ISO/IEC 18033-4:2005(E) © ISO/IEC 2005 This preview is downloaded from www.sis.se. Buy the entire standard via https://www.sis.se/std-906455 ISO/IEC 18033-4:2005(E) PDF disclaimer This PDF file may contain embedded typefaces. In accordance with Adobe's licensing policy, this file may be printed or viewed but shall not be edited unless the typefaces which are embedded are licensed to and installed on the computer performing the editing. In downloading this file, parties accept therein the responsibility of not infringing Adobe's licensing policy. The ISO Central Secretariat accepts no liability in this area. Adobe is a trademark of Adobe Systems Incorporated. Details of the software products used to create this PDF file can be found in the General Info relative to the file; the PDF-creation parameters were optimized for printing. Every care has been taken to ensure that the file is suitable for use by ISO member bodies. In the unlikely event that a problem relating to it is found, please inform the Central Secretariat at the address given below. © ISO/IEC 2005 All rights reserved. Unless otherwise specified, no part of this publication may be reproduced or utilized in any form or by any means, electronic or mechanical, including photocopying and microfilm, without permission in writing from either ISO at the address below or ISO's member body in the country of the requester.
    [Show full text]
  • The Rc4 Stream Encryption Algorithm
    TTHEHE RC4RC4 SSTREAMTREAM EENCRYPTIONNCRYPTION AALGORITHMLGORITHM William Stallings Stream Cipher Structure.............................................................................................................2 The RC4 Algorithm ...................................................................................................................4 Initialization of S............................................................................................................4 Stream Generation..........................................................................................................5 Strength of RC4 .............................................................................................................6 References..................................................................................................................................6 Copyright 2005 William Stallings The paper describes what is perhaps the popular symmetric stream cipher, RC4. It is used in the two security schemes defined for IEEE 802.11 wireless LANs: Wired Equivalent Privacy (WEP) and Wi-Fi Protected Access (WPA). We begin with an overview of stream cipher structure, and then examine RC4. Stream Cipher Structure A typical stream cipher encrypts plaintext one byte at a time, although a stream cipher may be designed to operate on one bit at a time or on units larger than a byte at a time. Figure 1 is a representative diagram of stream cipher structure. In this structure a key is input to a pseudorandom bit generator that produces a stream
    [Show full text]
  • Stream Cipher Designs: a Review
    SCIENCE CHINA Information Sciences March 2020, Vol. 63 131101:1–131101:25 . REVIEW . https://doi.org/10.1007/s11432-018-9929-x Stream cipher designs: a review Lin JIAO1*, Yonglin HAO1 & Dengguo FENG1,2* 1 State Key Laboratory of Cryptology, Beijing 100878, China; 2 State Key Laboratory of Computer Science, Institute of Software, Chinese Academy of Sciences, Beijing 100190, China Received 13 August 2018/Accepted 30 June 2019/Published online 10 February 2020 Abstract Stream cipher is an important branch of symmetric cryptosystems, which takes obvious advan- tages in speed and scale of hardware implementation. It is suitable for using in the cases of massive data transfer or resource constraints, and has always been a hot and central research topic in cryptography. With the rapid development of network and communication technology, cipher algorithms play more and more crucial role in information security. Simultaneously, the application environment of cipher algorithms is in- creasingly complex, which challenges the existing cipher algorithms and calls for novel suitable designs. To accommodate new strict requirements and provide systematic scientific basis for future designs, this paper reviews the development history of stream ciphers, classifies and summarizes the design principles of typical stream ciphers in groups, briefly discusses the advantages and weakness of various stream ciphers in terms of security and implementation. Finally, it tries to foresee the prospective design directions of stream ciphers. Keywords stream cipher, survey, lightweight, authenticated encryption, homomorphic encryption Citation Jiao L, Hao Y L, Feng D G. Stream cipher designs: a review. Sci China Inf Sci, 2020, 63(3): 131101, https://doi.org/10.1007/s11432-018-9929-x 1 Introduction The widely applied e-commerce, e-government, along with the fast developing cloud computing, big data, have triggered high demands in both efficiency and security of information processing.
    [Show full text]
  • On the Design and Analysis of Stream Ciphers Hell, Martin
    On the Design and Analysis of Stream Ciphers Hell, Martin 2007 Link to publication Citation for published version (APA): Hell, M. (2007). On the Design and Analysis of Stream Ciphers. Department of Electrical and Information Technology, Lund University. Total number of authors: 1 General rights Unless other specific re-use rights are stated the following general rights apply: Copyright and moral rights for the publications made accessible in the public portal are retained by the authors and/or other copyright owners and it is a condition of accessing publications that users recognise and abide by the legal requirements associated with these rights. • Users may download and print one copy of any publication from the public portal for the purpose of private study or research. • You may not further distribute the material or use it for any profit-making activity or commercial gain • You may freely distribute the URL identifying the publication in the public portal Read more about Creative commons licenses: https://creativecommons.org/licenses/ Take down policy If you believe that this document breaches copyright please contact us providing details, and we will remove access to the work immediately and investigate your claim. LUND UNIVERSITY PO Box 117 221 00 Lund +46 46-222 00 00 On the Design and Analysis of Stream Ciphers Martin Hell Ph.D. Thesis September 13, 2007 Martin Hell Department of Electrical and Information Technology Lund University Box 118 S-221 00 Lund, Sweden e-mail: [email protected] http://www.eit.lth.se/ ISBN: 91-7167-043-2 ISRN: LUTEDX/TEIT-07/1039-SE c Martin Hell, 2007 Abstract his thesis presents new cryptanalysis results for several different stream Tcipher constructions.
    [Show full text]
  • Linear Statistical Weakness of Alleged RC4 Keystream Generator
    Linear Statistical Weakness of Alleged RC4 Keystream Generator Jovan Dj. GoliC * School of Electrical Engineering, University of Belgrade Bulevar Revolucije 73, 11001 Beograd, Yugoslavia Abstract. A keystream generator known as RC4 is analyzed by the lin- ear model approach. It is shown that the second binary derivative of the least significant bit output sequence is correlated to 1 with the corre- lation coefficient close to 15 ' 2-3" where n is the variable word size of RC4. The output sequence length required for the linear statistical weak- ness detection may be realistic in high speed applications if n < 8. The result can be used to distinguish RC4 from other keystream generators and to determine the unknown parameter n, as well as for the plaintext uncertainty reduction if n is small. 1 Introduction Any keystream generator for practical stream cipher applications can generally be represented as an aiit,onomous finite-state machine whose initial state and possibly the next-state and output functions as well are secret key dependent. A common type of keystream generators consists of a number of possibly irregularly clocked linear feedback shift registers (LFSRs) that are combined by a function with or without memory. Standard cryptographic criteria such as a large period, a high linear complexity, and good statistical properties are thus relatively easily satisfied, see [16], [17], but such a generator may in principle be vulnerable to various divide-and-conquer attacks in the known plaintext (or ciphertext-only) scenario, where the objective is to reconstruct, the secret key controlled LFSR initial states from the known keystream sequence, for a survey see [17] and [6].
    [Show full text]
  • Grein a New Non-Linear Cryptoprimitive
    UNIVERSITY OF BERGEN Grein A New Non-Linear Cryptoprimitive by Ole R. Thorsen Thesis for the degree Master of Science December 2013 in the Faculty of Mathematics and Natural Sciences Department of Informatics Acknowledgements I want to thank my supervisor Tor Helleseth for all his help during the writing of this thesis. Further, I wish to thank the Norwegian National Security Authority, for giving me access to their Grein cryptosystem. I also wish to thank all my colleagues at the Selmer Centre, for all the inspiring discus- sions. Most of all I wish to thank prof. Matthew Parker for all his input, and my dear friends Stian, Mikal and Jørgen for their spellchecking, and socialising in the breaks. Finally, I wish to thank my girlfriend, Therese, and my family, for their continuous sup- port during the writing of this thesis. Without you, this would not have been possible. i Contents Acknowledgementsi List of Figures iv List of Tablesv 1 Introduction1 2 Cryptography2 2.1 Classical Cryptography............................3 2.2 Modern Cryptography.............................4 3 Stream Ciphers5 3.1 Stream Cipher Fundamentals.........................5 3.2 Classification of Stream Ciphers........................6 3.3 One-Time Pad.................................7 4 Building Blocks8 4.1 Boolean Functions...............................8 4.1.1 Cryptographic Properties....................... 10 4.2 Linear Feedback Shift Registers........................ 11 4.2.1 The Recurrence Relation....................... 12 4.2.2 The Matrix Method.......................... 12 4.2.3 Characteristic Polynomial....................... 13 4.2.4 Period of a Sequence.......................... 14 4.3 Linear Complexity............................... 16 4.4 The Berlekamp-Massey Algorithm...................... 16 4.5 Non-Linear Feedback Shift Registers....................
    [Show full text]