Block Ciphers. Advanced Encryption Standard (AES)

Similar documents
Chapter 3 Block Ciphers and the Data Encryption Standard

CIS 6930/4930 Computer and Network Security. Topic 3.1 Secret Key Cryptography (Cont d)

Computer Security. 08. Cryptography Part II. Paul Krzyzanowski. Rutgers University. Spring 2018

Goals of Modern Cryptography

Introduction to Cryptographic Systems. Asst. Prof. Mihai Chiroiu

Outline. Data Encryption Standard. Symmetric-Key Algorithms. Lecture 4

EEC-484/584 Computer Networks

Secret Key Cryptography

CHAPTER 6. SYMMETRIC CIPHERS C = E(K2, E(K1, P))

Winter 2011 Josh Benaloh Brian LaMacchia

Computer Security 3/23/18

Network Security Essentials Chapter 2

Introduction to Cryptography. Steven M. Bellovin September 27,

CSC574: Computer & Network Security

Lecture 1 Applied Cryptography (Part 1)

Symmetric Cryptography

Symmetric Encryption Algorithms

Data Encryption Standard (DES)

Computer Security CS 526

3 Symmetric Key Cryptography 3.1 Block Ciphers Symmetric key strength analysis Electronic Code Book Mode (ECB) Cipher Block Chaining Mode (CBC) Some

Advanced Encryption Standard and Modes of Operation. Foundations of Cryptography - AES pp. 1 / 50

ECE596C: Handout #7. Analysis of DES and the AES Standard. Electrical and Computer Engineering, University of Arizona, Loukas Lazos

Secret Key Cryptography (Spring 2004)

page 1 Introduction to Cryptography Benny Pinkas Lecture 3 November 18, 2008 Introduction to Cryptography, Benny Pinkas

Symmetric Encryption. Thierry Sans

CS6701- CRYPTOGRAPHY AND NETWORK SECURITY UNIT 2 NOTES

Applied Cryptography Data Encryption Standard

Stream Ciphers and Block Ciphers

Encryption Details COMP620

Block Cipher Operation. CS 6313 Fall ASU

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

6 Block Ciphers. 6.1 Block Ciphers CA642: CRYPTOGRAPHY AND NUMBER THEORY 1

EEC-682/782 Computer Networks I

18-642: Cryptography 11/15/ Philip Koopman

More on Cryptography CS 136 Computer Security Peter Reiher January 19, 2017

Cryptography Symmetric Encryption Class 2

n-bit Output Feedback

Lecture 2: Secret Key Cryptography

3 Symmetric Cryptography

Content of this part

Introduction to Cryptography. Lecture 2. Benny Pinkas. Perfect Cipher. Perfect Ciphers. Size of key space

Cryptography Functions

Symmetric Key Encryption. Symmetric Key Encryption. Advanced Encryption Standard ( AES ) DES DES DES 08/01/2015. DES and 3-DES.

Conventional Encryption: Modern Technologies

CSE 127: Computer Security Cryptography. Kirill Levchenko

Presented by: Kevin Hieb May 2, 2005

Double-DES, Triple-DES & Modes of Operation

P2_L6 Symmetric Encryption Page 1

L3: Basic Cryptography II. Hui Chen, Ph.D. Dept. of Engineering & Computer Science Virginia State University Petersburg, VA 23806

CENG 520 Lecture Note III

Computer Security. 08r. Pre-exam 2 Last-minute Review Cryptography. Paul Krzyzanowski. Rutgers University. Spring 2018

Cryptography and Network Security

Cryptography [Symmetric Encryption]

CPSC 467b: Cryptography and Computer Security

Symmetric Key Cryptography

CPSC 467: Cryptography and Computer Security

Introduction to Network Security Missouri S&T University CPE 5420 Data Encryption Standard

Understanding Cryptography A Textbook for Students and Practitioners by Christof Paar and Jan Pelzl

Introduction to Modern Cryptography. Lecture 2. Symmetric Encryption: Stream & Block Ciphers

ECE 646 Lecture 8. Modes of operation of block ciphers

Stream Ciphers and Block Ciphers

CIS 4360 Introduction to Computer Security Fall WITH ANSWERS in bold. First Midterm

Implementation and Performance analysis of Skipjack & Rijndael Algorithms. by Viswnadham Sanku ECE646 Project Fall-2001

Jaap van Ginkel Security of Systems and Networks

CSC 474/574 Information Systems Security

Lecture 4: Symmetric Key Encryption

Block cipher modes. Lecturers: Mark D. Ryan and David Galindo. Cryptography Slide: 75

9/30/2016. Cryptography Basics. Outline. Encryption/Decryption. Cryptanalysis. Caesar Cipher. Mono-Alphabetic Ciphers

Introduction to Symmetric Cryptography

Cryptography Basics. IT443 Network Security Administration Slides courtesy of Bo Sheng

Making and Breaking Ciphers

CIS 6930/4930 Computer and Network Security. Topic 3.2 Secret Key Cryptography Modes of Operation

Crypto: Symmetric-Key Cryptography

CPSC 467b: Cryptography and Computer Security

Lecture 3: Symmetric Key Encryption

18-642: Cryptography

Chapter 6 Contemporary Symmetric Ciphers

Block Ciphers. Lucifer, DES, RC5, AES. CS 470 Introduction to Applied Cryptography. Ali Aydın Selçuk. CS470, A.A.Selçuk Block Ciphers 1

Fundamentals of Cryptography

Cryptography MIS

7. Symmetric encryption. symmetric cryptography 1

Modern Symmetric Block cipher

Comp527 status items. Crypto Protocols, part 2 Crypto primitives. Bart Preneel July Install the smart card software. Today

Goals for Today. Substitution Permutation Ciphers. Substitution Permutation stages. Encryption Details 8/24/2010

Cryptography 2017 Lecture 3

Private-Key Encryption

UNIT - II Traditional Symmetric-Key Ciphers. Cryptography & Network Security - Behrouz A. Forouzan

CSCI 454/554 Computer and Network Security. Topic 3.2 Secret Key Cryptography Modes of Operation

Secret Key Cryptography Overview

Block Ciphers Introduction

CPSC 467b: Cryptography and Computer Security

Cryptography III: Symmetric Ciphers

Introduction to Cryptology. Lecture 17

Processing with Block Ciphers

Symmetric key cryptography

SECRET KEY: STREAM CIPHERS & BLOCK CIPHERS

CSC/ECE 574 Computer and Network Security. Processing with Block Ciphers. Issues for Block Chaining Modes

ENEE 459-C Computer Security. Symmetric key encryption in practice: DES and AES algorithms

Scanned by CamScanner

Lecture IV : Cryptography, Fundamentals

Transcription:

Network Security - ISA 656 Angelos Stavrou September 28, 2008 Codes vs. K = {0, 1} l P = {0, 1} m C = {0, 1} n, C C E : P K C D : C K P p P, k K : D(E(p, k), k) = p It is infeasible to find F : P C K Let s start again, in English... 2 / 32 Codes vs. Codes vs. A cryptosystem is pair of algorithms that take a key and convert plaintext to ciphertext and back. Plaintext is what you want to protect; ciphertext should appear to be random gibberish. The design and analysis of today s cryptographic algorithms is highly mathematical. Do not try to design your own algorithms. Codes vs. operate syntactically, on letters or groups of letters: A D, B E, etc. Codes operate semantically, on words, phrases, or sentences, per this 1910 codebook 3 / 32 4 / 32

Codes vs. Codes vs. There should be no way short of enumerating all possible keys to find the key from any reasonable amount of ciphertext and plaintext, nor any way to produce plaintext from ciphertext without the key. Enumerating all possible keys must be infeasible. The ciphertext must be indistinguishable from true random values. 5 / 32 6 / 32 Codes vs. 1883 Kerckhoffs Principles 1917-1918 cipher (one-time pad) 1920s-1940s Mathematicization and mechanization of cryptography and cryptanalysis 1973 U.S. National Bureau of Standards issues a public call for a standard cipher; this led to the adoption of the Data (DES) 1976 Diffie and Hellman describe public key cryptography Codes vs. The system must not be required to be secret, and it must be able to fall into the hands of the enemy without inconvenience. In other words, the security of the system must rest entirely on the secrecy of the key. 7 / 32 8 / 32

Codes vs. Exclusive-OR a key stream tape with the plaintext Online encryption of teletype traffic, combined with transmission For a one-time pad, which is provably secure, use true-random keying tapes and never reuse the keying material. If keying material is reusable, it s called a stream cipher = Snake oil alert! If the key stream is algorithmically generated, it s not a one-time pad! Codes vs. Really long key tapes are unwieldy, so Vernam tried XORing the output of two modestly-long looped tapes Example: key tapes of 999 and 1000 characters This repeats and it was cracked easily, way back when 9 / 32 10 / 32 Codes vs. Mechanical encryptors (Vernam, Enigma, Hagelin, Scherbius) Mathematical cryptanalysis (Friedman, Rejewski et al, Bletchley Park) Machine-aided cryptanalysis (Friedman, Turing et al.) Codes vs. Until the 1970s, most strong ciphers were government secrets The spread of computers created a new threat Reportedly, the Soviets eavesdropped on U.S. grain negotiators conversations NBS (now called NIST) issued a public call for a cipher; eventually, IBM responded The eventual result via a secret process was DES 11 / 32 12 / 32

Codes vs. Merkle invents a public key distribution scheme Diffie and Hellman invent public key encryption and digital signatures, but do not devise a suitable algorithm with all of the desired properties. Codes vs. Encryption is completely computerized, and operates on bits The basic primitives of encryption are combined to produce very powerful results Encryption is by far the strongest weapon in the computer security arsenal; host and operating system software is by far the weakest link Bad software trumps good crypto 13 / 32 14 / 32 Basic of Operate on a fixed-length set of bits Output blocksize generally the same as input blocksize Well-known examples: DES (56-bit keys; 64-bit blocksize); AES (128-, 192-, and 256-bit keys; 128-bit blocksize) Basic of Basic of Optional key scheduling convert supplied key to internal form Multiple rounds of combining the plaintext with the key. DES has 16 rounds; AES has 10-14 rounds, depending on key length 15 / 32 16 / 32

Basic of Basic of 17 / 32 18 / 32 For each round: Run the rounds backwards Basic of 1. Divide the input block in half. The right half of each round becomes the left half of the next round s input. 2. Take the right half, pass it through a non-linear function of data and key, and exclusive-or the result with the current input s left half. Basic of In the example, L i+1 is passed unchanged to the previous round (as R i ) Accordingly, it can be fed into F(K i ) to be XORed with R i+1 to produce L i 3. The output of that function becomes the right half of the next round s input. 4. This is known as a Fiestel network 19 / 32 20 / 32

Basic of The key size is too short a machine to crack DES was built in 1998. (Charges that NSA could crack DES were leveled in 1979. But the claim that NSA designed in a back door are false.) The blocksize is too short. It depends on bit-manipulation, and is too slow in software Block k-bit Properties of Mode NIST issued an open call for submissions 15 ciphers were submitted, from all over the world Several open conferences were held (and the NSA did its own private evaluations) 5 ciphers were eliminated as not secure enough 5 more were dropped for inefficiency or low security margin Of the 5 finalists, Rijndael a Belgian submission was chosen because of good security and very high efficiency across a wide range of platforms 21 / 32 22 / 32 Block k-bit Properties of Mode Input block viewed as a byte array; key viewed as a two-dimensional matrix Each round consists of a series of simple, byte-oriented operations: ByteSubstitution, ShiftRow, MixColumn, AddRoundKey. The key is mixed with the entire block in each round The basic operations are individually reasonably tractable mathematically, but are combined in a hard-to-invert fashion. Block k-bit Properties of Mode Direct use of a block cipher is inadvisable Enemy can build up code book of plaintext/ciphertext equivalents Beyond that, direct use only works on messages that are a multiple of the cipher block size in length Solution: five standard : (ECB), Block (CBC), (CFB), Output (OFB), and Counter (CTR). 23 / 32 24 / 32

Block k-bit Properties of Mode Direct use of the block cipher Used primarily to transmit encrypted keys Very weak if used for general-purpose encryption; never use it for a file or a message. We write {P } k C to denote encryption of plaintext P with key k to produce ciphertext C Block k-bit Properties of Mode 25 / 32 26 / 32 Block Block k-bit Properties of Mode Block k-bit Properties of Mode The ciphertext of each encrypted block depends on the plaintext of all preceeding blocks. There is a dummy initial ciphertext block C 0 known as the Initialization Vector (IV); the receiver must know this value. Consider a 4-block message: C 1 C 2 C 3 C 4 = {P 1 IV } k = {P 2 C 1 } k = {P 3 C 2 } k = {P 4 C 3 } k If C 2 is damaged during transmission, what happens to the plaintext? 27 / 32 28 / 32

Block k-bit Properties of Mode Look at the decryption process, where C is a garbled version of C: P 1 = {C 1 } k 1 IV P 2 = {C 2} k 1 C 1 P 3 = {C 3 } k 1 C 2 P 4 = {C 4 } k 1 C 3 P 1 depends only on C 1 and IV, and is unaffected P 2 depends on C 2 and C 1, and hence is garbled P 3 depends on C 3 and C 2, and is also garbled. The enemy can control the change to P 3. P 4 depends on C 4 and C 3, and not C 2 ; it thus isn t affected. Block k-bit Properties of Mode Consider the encrypted message IV, C 1, C 2, C 3, C 4, C 5 The shortened message IV, C 1, C 2, C 3, C 4 appears valid The truncated message C 2, C 3, C 4, C 5 is valid: C 2 acts as the IV. Even C 2, C 3, C 4 is valid, and will decrypt properly. Any subset of a CBC message will decrypt cleanly. If we snip out blocks, leaving IV, C 1, C 4, C 5, we only garble one block of plaintext. Conclusion: if you want message integrity, you have to do it yourself. Conclusion: Two blocks change, one of them predicatably 29 / 32 30 / 32 k-bit Properties of Mode Block k-bit Properties of Mode Block k-bit Properties of Mode Underlying block cipher used only in encryption mode path actually incorporates a shift register; some of the previous cycle s ciphertext can be retained. 8-bit CFB is good for asynchronous terminal traffic. Errors propagate while bad data is in the shift register 17 bytes for CFB 8 when using AES. Copes gracefully with deletion of n-bit unit 31 / 32 32 / 32