# Overview of Symmetric Encryption

Save this PDF as:

Size: px
Start display at page:

## Transcription

1 CS 361S Overview of Symmetric Encryption Vitaly Shmatikov

2 Reading Assignment Read Kaufman and 4.2 slide 2

3 Basic Problem ? Given: both parties already know the same secret Goal: send a message confidentially How is this achieved in practice? Any communication system that aims to guarantee confidentiality must solve this problem slide 3

4 Kerckhoffs's Principle An encryption scheme should be secure even if enemy knows everything about it except the key Attacker knows all algorithms Attacker does not know random numbers Do not rely on secrecy of the algorithms ( security by obscurity ) Easy lesson: use a good random number generator! Full name: Jean-Guillaume-Hubert-Victor- François-Alexandre-Auguste Kerckhoffs von Nieuwenhof slide 4

5 Randomness Matters! slide 5

6 (contains diagram) One-Time Pad (Vernam Cipher) = = = Key is a random bit sequence as long as the plaintext Encrypt by bitwise XOR of plaintext and key: ciphertext = plaintext key Decrypt by bitwise XOR of ciphertext and key: ciphertext key = (plaintext key) key = plaintext (key key) = plaintext Cipher achieves perfect secrecy if and only if there are as many possible keys as possible plaintexts, and every key is equally likely (Claude Shannon, 1949) slide 6

7 Diagram Transcription Sender has a bit-stream message and a bit-stream key of the same length. The ciphertext is defined as message[i] XOR key[i] for every i in the message. The recipient can decrypt the message by performing the identical operation but using the ciphertext instead of the message, because: ciphertext xor key = (plaintext xor key) xor key = plaintext xor (key xor key) = plaintext xor ( ) = plaintext

8 Advantages of One-Time Pad Easy to compute Encryption and decryption are the same operation Bitwise XOR is very cheap to compute As secure as theoretically possible Given a ciphertext, all plaintexts are equally likely, regardless of attacker s computational resources if and only if the key sequence is truly random True randomness is expensive to obtain in large quantities if and only if each key is as long as the plaintext But how do the sender and the receiver communicate the key to each other? Where do they store the key? slide 8

9 Problems with One-Time Pad Key must be as long as the plaintext Impractical in most realistic scenarios Still used for diplomatic and intelligence traffic Does not guarantee integrity One-time pad only guarantees confidentiality Attacker cannot recover plaintext, but can easily change it to something else Insecure if keys are reused Attacker can obtain XOR of plaintexts slide 9

10 (contains diagram) No Integrity = = = Key is a random bit sequence as long as the plaintext Encrypt by bitwise XOR of plaintext and key: ciphertext = plaintext key Decrypt by bitwise XOR of ciphertext and key: ciphertext key = (plaintext key) key = plaintext (key key) = plaintext slide 10

11 Diagram transcription No integrity is provided, because if the attacker flips bit n of the ciphertext while it is in transit, then after being decrypted bit n of the plaintext will be flipped. That is to say that while the attacker cannot know the contents of the message, he or she can choose to flip any bits from their original values.

12 (contains diagram) Dangers of Reuse P1 = = C = P2 = = C Learn relationship between plaintexts C1 C2 = (P1 K) (P2 K) = (P1 P2) (K K) = P1 P2 slide 12

13 Diagram Transcription If two ciphertexts are generated using the same key, and the attacker gains access to the ciphertexts (and knows that they were generated with the same key), then: ciphertext1 = plaintext1 xor key ciphertext2 = plaintext2 xor key So ciphertext1 xor ciphertext2 = (plaintext 1 xor key) xor (plaintext2 xor key) = (plaintext1 xor plaintext2) xor (key xor key) = (plaintext1 xor plaintext2)

14 Reducing Key Size What to do when it is infeasible to pre-share huge random keys? Use special cryptographic primitives: block ciphers, stream ciphers Single key can be re-used (with some restrictions) Not as theoretically secure as one-time pad slide 14

15 Block Ciphers Operates on a single chunk ( block ) of plaintext For example, 64 bits for DES, 128 bits for AES Same key is reused for each block (can use short keys) Result should look like a random permutation Not impossible to break, just very expensive If there is no more efficient algorithm (unproven assumption!), can only break the cipher by brute-force, tryevery-possible-key search Time and cost of breaking the cipher exceed the value and/or useful lifetime of protected information slide 15

16 Permutation CODE becomes DCEO For N-bit input, N! possible permutations Idea: split plaintext into blocks, for each block use secret key to pick a permutation, rinse and repeat Without the key, permutation should look random slide 16

17 A Bit of Block Cipher History Playfair and variants (from 1854 until WWII) Feistel structure Textbook Ladder structure: split input in half, put one half through the round and XOR with the other half After 3 random rounds, ciphertext indistinguishable from a random permutation DES: Data Encryption Standard Invented by IBM, issued as federal standard in bit blocks, 56-bit key + 8 bits for parity Textbook Very widely used (usually as 3DES) until recently 3DES: DES + inverse DES + DES (with 2 or 3 different keys) slide 17

18 (contains diagram, no transcription) DES Operation (Simplified) Block of plaintext Key S S S S S S S S repeat for several rounds S S S S Add some secret key bits to provide confusion Each S-box transforms its input bits in a random-looking way to provide diffusion (spread plaintext bits throughout ciphertext) Block of ciphertext Procedure must be reversible (for decryption) slide 18

19 (contains diagram, no transcription) Remember SHA-1? Current message block Constant value Very similar to a block cipher, with message itself used as the key for each round Buffer contains final hash value slide 19

20 Advanced Encryption Standard (AES) US federal standard as of 2001 Based on the Rijndael algorithm 128-bit blocks, keys can be 128, 192 or 256 bits Unlike DES, does not use Feistel structure The entire block is processed during each round Design uses some clever math See section 8.5 of the textbook for a concise summary slide 20

21 (contains diagram) Basic Structure of Rijndael 128-bit plaintext (arranged as 4x4 array of 8-bit bytes) 128-bit key S shuffle the array (16x16 substitution table) Shift rows Mix columns shift array rows (1 st unchanged, 2 nd left by 1, 3 rd left by 2, 4 th left by 3) mix 4 bytes in each column (each new byte depends on all bytes in old column) add key for this round Expand key repeat 10 times slide 21

22 Diagram Transcription The basic structure of Rijndael is to take the 128-bit plaintext, interpret it as a 4x4 matrix of 8-bite bytes, and then: - shuffle the array according to a substitution table - shift the rows - mix the 4-byte columns - mix in key material - repeat 10 times

23 Encrypting a Large Message So, we ve got a good block cipher, but our plaintext is larger than 128-bit block size Electronic Code Book (ECB) mode Split plaintext into blocks, encrypt each one separately using the block cipher Cipher Block Chaining (CBC) mode Split plaintext into blocks, XOR each block with the result of encrypting previous blocks Also various counter modes, feedback modes, etc. slide 23

24 (contains diagram) ECB Mode plaintext block cipher key key key key key block cipher block cipher block cipher block cipher ciphertext Identical blocks of plaintext produce identical blocks of ciphertext No integrity checks: can mix and match blocks slide 24

25 Diagram Transcription The plaintext is divided into blocks, and each block is individually encrypted using the key. The ciphertext is the output blocks concatenated with each other.

26 (contains diagram, no transcription [visual example]) Information Leakage in ECB Mode [Wikipedia] Encrypt in ECB mode slide 26

27 Adobe Passwords Stolen (2013) 153 million account passwords 56 million of them unique Encrypted using 3DES in ECB mode rather than hashed Password hints slide 27

28 (contains diagram) CBC Mode: Encryption plaintext Initialization vector (random) key key key key Sent with ciphertext (preferably encrypted) block cipher block cipher block cipher block cipher ciphertext Identical blocks of plaintext encrypted differently Last cipherblock depends on entire plaintext Still does not guarantee integrity slide 28

29 Diagram Transcription The first block of the plaintext is XOR'ed with the IV (random data), before being encrypted. The result of this encryption is the first block of the ciphertext, and then is XOR'ed with the plaintext of the second block before being encrypted, etc. The IV is pre-pended to the ciphertext (as it is necessary for decryption)

30 (contains diagram) CBC Mode: Decryption plaintext Initialization vector key key key key decrypt decrypt decrypt decrypt ciphertext slide 30

31 Diagram Transcription To decrypt in CBC mode, take the first block of the ciphertext (this is the IV). Then decrypt the second block of the ciphertext using the key, and XOR the result as the IV. This is the first block of plaintext. Then take the third block of the ciphertext, decrypt it using the key, and XOR the result with the second block of the ciphertext. This is the second block of plaintext. Rinse and repeat.

32 (contains diagram, no transcription [visual example]) ECB vs. CBC [Picture due to Bart Preneel] AES in ECB mode AES in CBC mode Similar plaintext blocks produce similar ciphertext blocks (not good!) slide 32

33 Choosing the Initialization Vector Key used only once No IV needed (can use IV=0) Key used multiple times Best: fresh, random IV for every message Can also use unique IV (eg, counter), but then the first step in CBC mode must be IV E(k, IV) Example: Windows BitLocker May not need to transmit IV with the ciphertext Multi-use key, unique messages Synthetic IV: IV F(k, message) F is a cryptographically secure keyed pseudorandom function slide 33

34 (contains diagram, no transcription, see earlier slide on CBC) CBC and Electronic Voting [Kohno, Stubblefield, Rubin, Wallach] plaintext Initialization vector (supposed to be random) key key key key DES DES DES DES ciphertext Found in the source code for Diebold voting machines: DesCBCEncrypt((des_c_block*)tmp, (des_c_block*)record.m_data, totalsize, DESKEY, NULL, DES_ENCRYPT) slide 34

35 (contains diagram) CTR (Counter Mode) Random IV plaintext key key key key Enc(IV) Enc(IV+1) Enc(IV+2) Enc(IV+3) IV ciphertext Still does not guarantee integrity Fragile if counter repeats slide 35

36 Diagram Transcription Instead of XORing with the IV and then the previous block of ciphertext, first XOR with the IV and then IV+1 and then IV+2 etc etc. Since this XORing happens before encryption, the resulting blocks of ciphertext will be arbitrarily different.

37 When Is a Cipher Secure? Hard to recover plaintext from ciphertext? What if attacker learns only some bits of the plaintext? Some function of the bits? Some partial information about the plaintext? Fixed mapping from plaintexts to ciphertexts? What if attacker sees two identical ciphertexts and infers that the corresponding plaintexts are identical? What if attacker guesses the plaintext can he verify his guess? Implication: encryption must be randomized or stateful slide 37

38 How Can a Cipher Be Attacked? Attackers knows ciphertext and encryption algthm What else does the attacker know? Depends on the application in which the cipher is used! Known-plaintext attack (stronger) Knows some plaintext-ciphertext pairs Chosen-plaintext attack (even stronger) Can obtain ciphertext for any plaintext of his choice Chosen-ciphertext attack (very strong) Can decrypt any ciphertext except the target Sometimes very realistic slide 38

39 Known-Plaintext Attack [From The Art of Intrusion ] Extracting password from an encrypted PKZIP file I opened the ZIP file and found a `logo.tif file, so I went to their main Web site and looked at all the files named `logo.tif. I downloaded them and zipped them all up and found one that matched the same checksum as the one in the protected ZIP file With known plaintext, PkCrack took 5 minutes to extract the key Biham-Kocher attack on PKZIP stream cipher slide 39

40 (contains diagram) Chosen-Plaintext Attack cipher(key,pin) PIN is encrypted and transmitted to bank Crook #1 changes his PIN to a number of his choice Crook #2 eavesdrops on the wire and learns ciphertext corresponding to chosen plaintext PIN repeat for any PIN value slide 40

41 Diagram Transcription Crook 1 changes his PIN at an ATM Pin is encrypted (Enc(PIN, Key)) and sent over the network Crrok 2 eavesdrops and thus learns a valid encryption of any given plaintext (the PIN entered by Crook 1)

42 Very Informal Intuition Minimum security requirement for a modern encryption scheme Security against chosen-plaintext attack Ciphertext leaks no information about the plaintext Even if the attacker correctly guesses the plaintext, he cannot verify his guess Every ciphertext is unique, encrypting same message twice produces completely different ciphertexts Security against chosen-ciphertext attack Integrity protection it is not possible to change the plaintext by modifying the ciphertext slide 42

43 The Chosen-Plaintext Game Attacker does not know the key He chooses as many plaintexts as he wants, and receives the corresponding ciphertexts When ready, he picks two plaintexts M 0 and M 1 He is even allowed to pick plaintexts for which he previously learned ciphertexts! He receives either a ciphertext of M 0, or a ciphertext of M 1 He wins if he guesses correctly which one it is slide 43

44 Meaning of Leaks No Information Idea: given a ciphertext, attacker should not be able to learn even a single bit of useful information about the plaintext Let Enc(M 0,M 1,b) be a magic box that returns encrypted M b 0 or 1 Given two plaintexts, the box always returns the ciphertext of the left plaintext or right plaintext Attacker can use this box to obtain the ciphertext of any plaintext M by submitting M 0 =M 1 =M, or he can try to learn even more by submitting M 0 M 1 Attacker s goal is to learn just this one bit b slide 44

45 Chosen-Plaintext Security Consider two experiments (A is the attacker) Experiment 0 Experiment 1 A interacts with Enc(-,-,0) A interacts with Enc(-,-,1) and outputs his guess of bit b and outputs his guess of bit b Identical except for the value of the secret bit b is attacker s guess of the secret bit Attacker s advantage is defined as Prob(A outputs 1 in Exp0) - Prob(A outputs 1 in Exp1)) Encryption scheme is chosen-plaintext secure if this advantage is negligible for any efficient A slide 45

46 Simple Example Any deterministic, stateless symmetric encryption scheme is insecure Attacker can easily distinguish encryptions of different plaintexts from encryptions of identical plaintexts This includes ECB mode of common block ciphers! Attacker A interacts with Enc(-,-,b) Let X,Y be any two different plaintexts C 1 Enc(X,X,b); C 2 Enc(X,Y,b); If C 1 =C 2 then b=0 else b=1 The advantage of this attacker A is 1 Prob(A outputs 1 if b=0)=0 Prob(A outputs 1 if b=1)=1 slide 46

47 (contains diagram) Encrypt + MAC Goal: confidentiality + integrity + authentication K1, K2 msg MAC=HMAC(K2,msg) Can tell if messages are the same! encrypt(msg), MAC(msg) Decrypt Breaks chosenplaintext security K1, K2 Alice Encrypt(K1,msg) encrypt(msg2), MAC(msg2) =? Verify MAC Bob MAC is deterministic: messages are equal their MACs are equal Solution: Encrypt, then MAC (what about MAC, then encrypt?) slide 47

48 Diagram Transcription If the MAC of the plaintext is appended to the ciphertext before being sent out, then an attacker can know if two messages contain the same plaintext (because the MACs will match). This breaks chosen plaintext security.

### Shift Cipher. Ahmet Burak Can Hacettepe University. Substitution Cipher. Enigma Machine. How perfect secrecy can be satisfied?

One Time Pad, Block Ciphers, Encryption Modes Ahmet Burak Can Hacettepe University abc@hacettepe.edu.tr Basic Ciphers Shift Cipher Brute-force attack can easily break Substitution Cipher Frequency analysis

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

CS 494/594 Computer and Network Security Dr. Jinyuan (Stella) Sun Dept. of Electrical Engineering and Computer Science University of Tennessee Fall 2010 1 Secret Key Cryptography Modes of operation Stream

### Overview of Cryptographic Tools for Data Security. Murat Kantarcioglu

UT DALLAS Erik Jonsson School of Engineering & Computer Science Overview of Cryptographic Tools for Data Security Murat Kantarcioglu Pag. 1 Purdue University Cryptographic Primitives We will discuss the

### Network Security - ISA 656 Introduction to Cryptography

Network Security - ISA 656 Angelos Stavrou September 18, 2007 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

6.857 Computer and Network Security Fall Term, 1997 Lecture 4 : 16 September 1997 Lecturer: Ron Rivest Scribe: Michelle Goldberg 1 Conditionally Secure Cryptography Conditionally (or computationally) secure

### Computer Science A Cryptography and Data Security. Claude Crépeau

Computer Science 308-547A Cryptography and Data Security Claude Crépeau These notes are, largely, transcriptions by Anton Stiglic of class notes from the former course Cryptography and Data Security (308-647A)

### Network Security. Abusayeed Saifullah. CS 5600 Computer Networks. These slides are adapted from Kurose and Ross 8-1

Network Security Abusayeed Saifullah CS 5600 Computer Networks These slides are adapted from Kurose and Ross 8-1 Goals v understand principles of network security: cryptography and its many uses beyond

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

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Module No. #01 Lecture No. #10 Symmetric Key Ciphers (Refer

### CS 758: Cryptography / Network Security

CS 758: Cryptography / Network Security offered in the Fall Semester, 2003, by Doug Stinson my office: DC 3122 my email address: dstinson@uwaterloo.ca my web page: http://cacr.math.uwaterloo.ca/~dstinson/index.html

### Cryptography and Network Security

Cryptography and Network Security Spring 2012 http://users.abo.fi/ipetre/crypto/ Lecture 3: Block ciphers and DES Ion Petre Department of IT, Åbo Akademi University January 17, 2012 1 Data Encryption Standard

### CSCE 465 Computer & Network Security

CSCE 465 Computer & Network Security Instructor: Dr. Guofei Gu http://courses.cse.tamu.edu/guofei/csce465/ Secret Key Cryptography (I) 1 Introductory Remarks Roadmap Feistel Cipher DES AES Introduction

### Network security and all ilabs

Network security and all ilabs Modern cryptography for communications security part 1 Benjamin Hof hof@in.tum.de Lehrstuhl für Netzarchitekturen und Netzdienste Fakultät für Informatik Technische Universität

### CIS433/533 - Computer and Network Security Cryptography

CIS433/533 - Computer and Network Security Cryptography Professor Kevin Butler Winter 2011 Computer and Information Science A historical moment Mary Queen of Scots is being held by Queen Elizabeth and

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

Developing and Investigation of a New Technique Combining Message Authentication and Encryption Eyas El-Qawasmeh and Saleem Masadeh Computer Science Dept. Jordan University for Science and Technology P.O.

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

Network Security Computer Networking Lecture 08 HKU SPACE Community College March 19, 2012 HKU SPACE CC CN Lecture 08 1/23 Outline Introduction Cryptography Algorithms Secret Key Algorithm Message Digest

### Talk announcement please consider attending!

Talk announcement please consider attending! Where: Maurer School of Law, Room 335 When: Thursday, Feb 5, 12PM 1:30PM Speaker: Rafael Pass, Associate Professor, Cornell University, Topic: Reasoning Cryptographically

### Security and Cryptography 1. Stefan Köpsell, Thorsten Strufe. Module 4: Basic Crypto, Stream Ciphers

Security and Cryptography 1 Stefan Köpsell, Thorsten Strufe Module 4: Basic Crypto, Stream Ciphers Disclaimer: Günter Schäfer, Mark Manulis, large parts from Dan Boneh Dresden, WS 16/17 Reprise from the

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

CS 494/594 Computer and Network Security Dr. Jinyuan (Stella) Sun Dept. of Electrical Engineering and Computer Science University of Tennessee Fall 2010 1 Introduction to Cryptography What is cryptography?

### Hash Functions. Integrity checks

Hash Functions EJ Jung slide 1 Integrity checks Integrity vs. Confidentiality! Integrity: attacker cannot tamper with message! Encryption may not guarantee integrity! Intuition: attacker may able to modify

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

CS-4920: Lecture 7 Secret key cryptography Reading Chapter 3 (pp. 59-75, 92-93) Today s Outcomes Discuss block and key length issues related to secret key cryptography Define several terms related to secret

### Error oracle attacks and CBC encryption. Chris Mitchell ISG, RHUL http://www.isg.rhul.ac.uk/~cjm

Error oracle attacks and CBC encryption Chris Mitchell ISG, RHUL http://www.isg.rhul.ac.uk/~cjm Agenda 1. Introduction 2. CBC mode 3. Error oracles 4. Example 1 5. Example 2 6. Example 3 7. Stream ciphers

### The Data Encryption Standard (DES)

The Data Encryption Standard (DES) As mentioned earlier there are two main types of cryptography in use today - symmetric or secret key cryptography and asymmetric or public key cryptography. Symmetric

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

Secret File Sharing Techniques using AES algorithm C. Navya Latha 200201066 Garima Agarwal 200305032 Anila Kumar GVN 200305002 1. Feature Overview The Advanced Encryption Standard (AES) feature adds support

### Cryptographic hash functions and MACs Solved Exercises for Cryptographic Hash Functions and MACs

Cryptographic hash functions and MACs Solved Exercises for Cryptographic Hash Functions and MACs Enes Pasalic University of Primorska Koper, 2014 Contents 1 Preface 3 2 Problems 4 2 1 Preface This is a

### SAMPLE EXAM QUESTIONS MODULE EE5552 NETWORK SECURITY AND ENCRYPTION ECE, SCHOOL OF ENGINEERING AND DESIGN BRUNEL UNIVERSITY UXBRIDGE MIDDLESEX, UK

SAMPLE EXAM QUESTIONS MODULE EE5552 NETWORK SECURITY AND ENCRYPTION September 2010 (reviewed September 2014) ECE, SCHOOL OF ENGINEERING AND DESIGN BRUNEL UNIVERSITY UXBRIDGE MIDDLESEX, UK NETWORK SECURITY

### Symmetric Key cryptosystem

SFWR C03: Computer Networks and Computer Security Mar 8-11 200 Lecturer: Kartik Krishnan Lectures 22-2 Symmetric Key cryptosystem Symmetric encryption, also referred to as conventional encryption or single

### Network Security. Modes of Operation. Steven M. Bellovin February 3, 2009 1

Modes of Operation Steven M. Bellovin February 3, 2009 1 Using Cryptography As we ve already seen, using cryptography properly is not easy Many pitfalls! Errors in use can lead to very easy attacks You

### 2.3: Hash Functions Message Digest (MD) MD2, MD4, MD5. Chapter 4: Security on the Application Layer Chapter 5: Security Concepts for Networks

Chapter 2: Security Techniques Background Secret Key Cryptography Public Key Cryptography Hash Functions Authentication Chapter 3: Security on Network and Transport Layer 2.3: Hash Functions Message Digest

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

Cryptography: Motivation Many areas have sensitive information, e.g. Data Structures and Algorithms Cryptography Goodrich & Tamassia Sections 3.1.3 & 3.1.4 Introduction Simple Methods Asymmetric methods:

### CRYPTOGRAPHIC PRIMITIVES AN INTRODUCTION TO THE THEORY AND PRACTICE BEHIND MODERN CRYPTOGRAPHY

CRYPTOGRAPHIC PRIMITIVES AN INTRODUCTION TO THE THEORY AND PRACTICE BEHIND MODERN CRYPTOGRAPHY Robert Sosinski Founder & Engineering Fellow Known as "America's Cryptologic Wing", is the only Air Force

### Security usually depends on the secrecy of the key, not the secrecy of the algorithm (i.e., the open design model!)

1 A cryptosystem has (at least) five ingredients: 1. 2. 3. 4. 5. Plaintext Secret Key Ciphertext Encryption algorithm Decryption algorithm Security usually depends on the secrecy of the key, not the secrecy

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

CS 494/594 Computer and Network Security Dr. Jinyuan (Stella) Sun Dept. of Electrical Engineering and Computer Science University of Tennessee Fall 2010 1 Hashes and Message Digests What hashes can do

### Lecture 4 Data Encryption Standard (DES)

Lecture 4 Data Encryption Standard (DES) 1 Block Ciphers Map n-bit plaintext blocks to n-bit ciphertext blocks (n = block length). For n-bit plaintext and ciphertext blocks and a fixed key, the encryption

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

CA642: CRYPTOGRAPHY AND NUMBER THEORY 1 6 Block Ciphers 6.1 Block Ciphers Block Ciphers Plaintext is divided into blocks of fixed length and every block is encrypted one at a time. A block cipher is a

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

Chair for Network Architectures and Services Department of Informatics TU München Prof. Carle Network Security Chapter 3 Symmetric Cryptography General Description Modes of ion Data ion Standard (DES)

### Data Encryption Standard (DES)

Data Encryption Standard (DES) DES Background The DES algorithm based on LUCIFER, designed by Horst Feistel, was developed at IBM in 1972. This algorithm was approved by the National Bureau of Standards

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

Network Security Security Crytographic algorithms Security Services Secret key (DES) Public key (RSA) Message digest (MD5) privacy authenticity Message integrity Secret Key Encryption Plain text Plain

### APNIC elearning: Cryptography Basics. Contact: esec02_v1.0

APNIC elearning: Cryptography Basics Contact: training@apnic.net esec02_v1.0 Overview Cryptography Cryptographic Algorithms Encryption Symmetric-Key Algorithm Block and Stream Cipher Asymmetric Key Algorithm

### Applied Cryptology. Ed Crowley

Applied Cryptology Ed Crowley 1 Basics Topics Basic Services and Operations Symmetric Cryptography Encryption and Symmetric Algorithms Asymmetric Cryptography Authentication, Nonrepudiation, and Asymmetric

### CS 161 Computer Security

Song Spring 2015 CS 161 Computer Security Discussion 11 April 7 & April 8, 2015 Question 1 RSA (10 min) (a) Describe how to find a pair of public key and private key for RSA encryption system. Find two

### Modes of Operation of Block Ciphers

Chapter 3 Modes of Operation of Block Ciphers A bitblock encryption function f: F n 2 Fn 2 is primarily defined on blocks of fixed length n To encrypt longer (or shorter) bit sequences the sender must

### 9/17/2015. Cryptography Basics. Outline. Encryption/Decryption. Cryptanalysis. Caesar Cipher. Mono-Alphabetic Ciphers

Cryptography Basics IT443 Network Security Administration Instructor: Bo Sheng Outline Basic concepts in cryptography system Secret cryptography Public cryptography Hash functions 1 2 Encryption/Decryption

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

CIS 6930 Emerging Topics in Network Security Topic 2. Network Security Primitives 1 Outline Absolute basics Encryption/Decryption; Digital signatures; D-H key exchange; Hash functions; Application of hash

### Authenticated encryption

Authenticated encryption Dr. Enigma Department of Electrical Engineering & Computer Science University of Central Florida wocjan@eecs.ucf.edu October 16th, 2013 Active attacks on CPA-secure encryption

### Cryptography and Network Security Block Cipher

Cryptography and Network Security Block Cipher Xiang-Yang Li Modern Private Key Ciphers Stream ciphers The most famous: Vernam cipher Invented by Vernam, ( AT&T, in 1917) Process the message bit by bit

### Lecture 5 - Cryptography

CSE497b Introduction to Computer and Network Security - Spring 2007 - Professors Jaeger Lecture 5 - Cryptography CSE497b - Spring 2007 Introduction Computer and Network Security Professor Jaeger www.cse.psu.edu/~tjaeger/cse497b-s07/

### Stream Ciphers. Example of Stream Decryption. Example of Stream Encryption. Real Cipher Streams. Terminology. Introduction to Modern Cryptography

Introduction to Modern Cryptography Lecture 2 Symmetric Encryption: Stream & Block Ciphers Stream Ciphers Start with a secret key ( seed ) Generate a keying stream i-th bit/byte of keying stream is a function

### Cryptography CS 555. Topic 3: One-time Pad and Perfect Secrecy. CS555 Spring 2012/Topic 3 1

Cryptography CS 555 Topic 3: One-time Pad and Perfect Secrecy CS555 Spring 2012/Topic 3 1 Outline and Readings Outline One-time pad Perfect secrecy Limitation of perfect secrecy Usages of one-time pad

### Overview of Public-Key Cryptography

CS 361S Overview of Public-Key Cryptography Vitaly Shmatikov slide 1 Reading Assignment Kaufman 6.1-6 slide 2 Public-Key Cryptography public key public key? private key Alice Bob Given: Everybody knows

### Title Goes Here An Introduction to Modern Cryptography. Mike Reiter

Title Goes Here An Introduction to Modern Cryptography Mike Reiter 1 Cryptography Study of techniques to communicate securely in the presence of an adversary Traditional scenario Goal: A dedicated, private

### Network Security (2) CPSC 441 Department of Computer Science University of Calgary

Network Security (2) CPSC 441 Department of Computer Science University of Calgary 1 Friends and enemies: Alice, Bob, Trudy well-known in network security world Bob, Alice (lovers!) want to communicate

### Symmetric Key Cryptography

Symmetric Key Cryptography Cryptography Intro Provides confidentiality Securely exchange information in an insecure environment Process: Plaintext Ciphertext Plaintext Encryption Decryption Unreadable,

### Message Authentication Codes

2 MAC Message Authentication Codes : and Cryptography Sirindhorn International Institute of Technology Thammasat University Prepared by Steven Gordon on 28 October 2013 css322y13s2l08, Steve/Courses/2013/s2/css322/lectures/mac.tex,

### Cryptography and Network Security Chapter 3

Cryptography and Network Security Chapter 3 Fifth Edition by William Stallings Lecture slides by Lawrie Brown (with edits by RHB) Chapter 3 Block Ciphers and the Data Encryption Standard All the afternoon

### Midterm Exam Solutions CS161 Computer Security, Spring 2008

Midterm Exam Solutions CS161 Computer Security, Spring 2008 1. To encrypt a series of plaintext blocks p 1, p 2,... p n using a block cipher E operating in electronic code book (ECB) mode, each ciphertext

### The Misuse of RC4 in Microsoft Word and Excel

The Misuse of RC4 in Microsoft Word and Excel Hongjun Wu Institute for Infocomm Research, Singapore hongjun@i2r.a-star.edu.sg Abstract. In this report, we point out a serious security flaw in Microsoft

### The Order of Encryption and Authentication for Protecting Communications (Or: How Secure is SSL?)

The Order of Encryption and Authentication for Protecting Communications (Or: How Secure is SSL?) Hugo Krawczyk Abstract. We study the question of how to generically compose symmetric encryption and authentication

### CS155. Cryptography Overview

CS155 Cryptography Overview Cryptography Is n A tremendous tool n The basis for many security mechanisms Is not n The solution to all security problems n Reliable unless implemented properly n Reliable

### CSC474/574 - Information Systems Security: Homework1 Solutions Sketch

CSC474/574 - Information Systems Security: Homework1 Solutions Sketch February 20, 2005 1. Consider slide 12 in the handout for topic 2.2. Prove that the decryption process of a one-round Feistel cipher

### Lecture 10: CPA Encryption, MACs, Hash Functions. 2 Recap of last lecture - PRGs for one time pads

CS 7880 Graduate Cryptography October 15, 2015 Lecture 10: CPA Encryption, MACs, Hash Functions Lecturer: Daniel Wichs Scribe: Matthew Dippel 1 Topic Covered Chosen plaintext attack model of security MACs

### Cryptography and Network Security Chapter 6

Cryptography and Network Security Chapter 6 Fifth Edition by William Stallings Lecture slides by Lawrie Brown (with edits by RHB) Chapter 6 Block Cipher Operation Many savages at the present day regard

### Computer and Network Security

Computer and Network Security c Copyright 2000 R. E. Newman Computer & Information Sciences & Engineering University Of Florida Gainesville, Florida 32611-6120 nemo@cise.ufl.edu Hashes (Pfleeger Ch. 3,

### 7! Cryptographic Techniques! A Brief Introduction

7! Cryptographic Techniques! A Brief Introduction 7.1! Introduction to Cryptography! 7.2! Symmetric Encryption! 7.3! Asymmetric (Public-Key) Encryption! 7.4! Digital Signatures! 7.5! Public Key Infrastructures

### Chair for Network Architectures and Services Department of Informatics TU München Prof. Carle. Network Security. Chapter 13

Chair for Network Architectures and Services Department of Informatics TU München Prof. Carle Network Security Chapter 13 Some More Secure Channel Issues Outline In the course we have yet only seen catastrophic

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

Chapter 11 Security+ Guide to Network Security Fundamentals, Third Edition Basic Cryptography What Is Steganography? Steganography Process of hiding the existence of the data within another file Example:

### CS Asymmetric-key Encryption. Prof. Clarkson Spring 2016

CS 5430 Asymmetric-key Encryption Prof. Clarkson Spring 2016 Review: block ciphers Encryption schemes: Enc(m; k): encrypt message m under key k Dec(c; k): decrypt ciphertext c with key k Gen(len): generate

### SECURITY IN NETWORKS

SECURITY IN NETWORKS GOALS Understand principles of network security: Cryptography and its many uses beyond confidentiality Authentication Message integrity Security in practice: Security in application,

### MAC. SKE in Practice. Lecture 5

MAC. SKE in Practice. Lecture 5 Active Adversary Active Adversary An active adversary can inject messages into the channel Active Adversary An active adversary can inject messages into the channel Eve

### EXAM questions for the course TTM4135 - Information Security May 2013. Part 1

EXAM questions for the course TTM4135 - Information Security May 2013 Part 1 This part consists of 5 questions all from one common topic. The number of maximal points for every correctly answered question

### Chapter 10 Security of Wireless LAN

Chapter 10 Security of Wireless LAN WEP WPA WPA2 [NetSec], WS 2008/2009 10.1 WLAN Authentication and Encryption WEP (Wired Equivalent Privacy) First Generation One way shared key authentication RC4 encryption

### lundi 1 octobre 2012 In a set of N elements, by picking at random N elements, we have with high probability a collision two elements are equal

Symmetric Crypto Pierre-Alain Fouque Birthday Paradox In a set of N elements, by picking at random N elements, we have with high probability a collision two elements are equal N=365, about 23 people are

MACs Message authentication and integrity Foundations of Cryptography Computer Science Department Wellesley College Table of contents Introduction MACs Constructing Secure MACs Secure communication and

### 1 Construction of CCA-secure encryption

CSCI 5440: Cryptography Lecture 5 The Chinese University of Hong Kong 10 October 2012 1 Construction of -secure encryption We now show how the MAC can be applied to obtain a -secure encryption scheme.

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

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Lecture No. # 11 Block Cipher Standards (DES) (Refer Slide

### Cryptography & Digital Signatures

Cryptography & Digital Signatures CS 594 Special Topics/Kent Law School: Computer and Network Privacy and Security: Ethical, Legal, and Technical Consideration Prof. Sloan s Slides, 2007, 2008 Robert H.

### 1 Data Encryption Algorithm

Date: Monday, September 23, 2002 Prof.: Dr Jean-Yves Chouinard Design of Secure Computer Systems CSI4138/CEG4394 Notes on the Data Encryption Standard (DES) The Data Encryption Standard (DES) has been

### CSE/EE 461 Lecture 23

CSE/EE 461 Lecture 23 Network Security David Wetherall djw@cs.washington.edu Last Time Naming Application Presentation How do we name hosts etc.? Session Transport Network Domain Name System (DNS) Data

### Authentication requirement Authentication function MAC Hash function Security of

UNIT 3 AUTHENTICATION Authentication requirement Authentication function MAC Hash function Security of hash function and MAC SHA HMAC CMAC Digital signature and authentication protocols DSS Slides Courtesy

### Lecture 9 - Message Authentication Codes

Lecture 9 - Message Authentication Codes Boaz Barak March 1, 2010 Reading: Boneh-Shoup chapter 6, Sections 9.1 9.3. Data integrity Until now we ve only been interested in protecting secrecy of data. However,

### Message Authentication Codes. Lecture Outline

Message Authentication Codes Murat Kantarcioglu Based on Prof. Ninghui Li s Slides Message Authentication Code Lecture Outline 1 Limitation of Using Hash Functions for Authentication Require an authentic

### Network Security. HIT Shimrit Tzur-David

Network Security HIT Shimrit Tzur-David 1 Goals: 2 Network Security Understand principles of network security: cryptography and its many uses beyond confidentiality authentication message integrity key

### 1 Step 1: Select... Files to Encrypt 2 Step 2: Confirm... Name of Archive 3 Step 3: Define... Pass Phrase

Contents I Table of Contents Foreword 0 Part I Introduction 2 1 What is?... 2 Part II Encrypting Files 1,2,3 2 1 Step 1: Select... Files to Encrypt 2 2 Step 2: Confirm... Name of Archive 3 3 Step 3: Define...

### Message Authentication

Message Authentication message authentication is concerned with: protecting the integrity of a message validating identity of originator non-repudiation of origin (dispute resolution) will consider the

### Lecture 9: Application of Cryptography

Lecture topics Cryptography basics Using SSL to secure communication links in J2EE programs Programmatic use of cryptography in Java Cryptography basics Encryption Transformation of data into a form that

### Chapter 4. Symmetric Encryption. 4.1 Symmetric encryption schemes

Chapter 4 Symmetric Encryption The symmetric setting considers two parties who share a key and will use this key to imbue communicated data with various security attributes. The main security goals are

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

Cryptography and Network Security Prof. D. Mukhopadhyay Department of Computer Science and Engineering Indian Institute of Technology, Kharagpur Module No. # 01 Lecture No. # 02 Overview on Modern Cryptography

### How Things Goes Wrong: Misuse of Cryptography in Secure System Design

CS 380S How Things Goes Wrong: Misuse of Cryptography in Secure System Design Vitaly Shmatikov slide 1 One-Time Pad ----- ----- ----- = 10111101 = 00110010 10001111 10111101 00110010 = Key is a random

### uses same key for encryption, decryption classical, conventional, single-key encryption

CEN 448 Security and Internet Protocols Chapter 2 Classical Encryption Techniques Dr. Mostafa Hassan Dahshan Computer Engineering Department College of Computer and Information Sciences King Saud University

### Client Server Registration Protocol

Client Server Registration Protocol The Client-Server protocol involves these following steps: 1. Login 2. Discovery phase User (Alice or Bob) has K s Server (S) has hash[pw A ].The passwords hashes are

### Properties of Secure Network Communication

Properties of Secure Network Communication Secrecy: Only the sender and intended receiver should be able to understand the contents of the transmitted message. Because eavesdroppers may intercept the message,

### Provable-Security Analysis of Authenticated Encryption in Kerberos

Provable-Security Analysis of Authenticated Encryption in Kerberos Alexandra Boldyreva Virendra Kumar Georgia Institute of Technology, School of Computer Science 266 Ferst Drive, Atlanta, GA 30332-0765

### Authentication and Encryption: How to order them? Motivation

Authentication and Encryption: How to order them? Debdeep Muhopadhyay IIT Kharagpur Motivation Wide spread use of internet requires establishment of a secure channel. Typical implementations operate in

### Cryptology introduction

Cryptology introduction Martin Stanek Department of Computer Science Comenius University stanek@dcs.fmph.uniba.sk Cryptology 1 (2015/16) Content Introduction security requirements Encryption simple examples,

### CSA E0 235: Cryptography (29/03/2015) (Extra) Lecture 3

CSA E0 235: Cryptography (29/03/2015) Instructor: Arpita Patra (Extra) Lecture 3 Submitted by: Mayank Tiwari Review From our discussion of perfect secrecy, we know that the notion of perfect secrecy has

### Fundamentals of Computer Security

Fundamentals of Computer Security Spring 2015 Radu Sion Intro Encryption Hash Functions A Message From Our Sponsors Fundamentals System/Network Security, crypto How do things work Why How to design secure

### Cryptography & Network Security

Cryptography & Network Security Lecture 1: Introduction & Overview 2002. 3. 27 chlim@sejong.ac.kr Common Terms(1) Cryptography: The study of mathematical techniques related to aspects of information security

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

Network Security CS 5490/6490 Fall 2015 Lecture Notes 8/26/2015 Chapter 2: Introduction to Cryptography What is cryptography? It is a process/art of mangling information in such a way so as to make it

### Evaluation of the RC4 Algorithm for Data Encryption

Evaluation of the RC4 Algorithm for Data Encryption Allam Mousa (1) and Ahmad Hamad (2) (1) Electrical Engineering Department An-Najah University, Nablus, Palestine (2) Systems Engineer PalTel Company,

### CRYPTOGRAPHIC ALGORITHMS (AES, RSA)

CALIFORNIA STATE POLYTECHNIC UNIVERSITY, POMONA CRYPTOGRAPHIC ALGORITHMS (AES, RSA) A PAPER SUBMITTED TO PROFESSOR GILBERT S. YOUNG IN PARTIAL FULFILLMENT OF THE REQUIREMENT FOR THE COURSE CS530 : ADVANCED

### Cryptography Exercises

Cryptography Exercises 1 Contents 1 source coding 3 2 Caesar Cipher 4 3 Ciphertext-only Attack 5 4 Classification of Cryptosystems-Network Nodes 6 5 Properties of modulo Operation 10 6 Vernam Cipher 11