Chapter 2 Basic Encryption and Decryption. csci5233 computer security & integrity 2 Encryption / Decryption encrypted transmission AB plaintext ciphertext.

Slides:



Advertisements
Similar presentations
CLASSICAL ENCRYPTION TECHNIQUES
Advertisements

Cryptography encryption authentication digital signatures
Using Cryptography to Secure Information. Overview Introduction to Cryptography Using Symmetric Encryption Using Hash Functions Using Public Key Encryption.
Classical Encryption Techniques Week 6-wend. One-Time Pad if a truly random key as long as the message is used, the cipher will be secure called a One-Time.
Making “Good” Encryption Algorithms
Cryptology Terminology and Early History. Cryptology Terms Cryptology –The science of concealing the meaning of messages and the discovery of the meaning.
EEC 693/793 Special Topics in Electrical Engineering Secure and Dependable Computing Lecture 4 Wenbing Zhao Department of Electrical and Computer Engineering.
EEC 688/788 Secure and Dependable Computing Lecture 4 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
Cryptography Cryptography: art or science of keeping messages secret Cryptology: branch of mathematics that studies the mathematical foundations of cryptographic.
CSE331: Introduction to Networks and Security Lecture 17 Fall 2002.
Network Management and Security
Chapter 2 – Classical Encryption Techniques. Classical Encryption Techniques Symmetric Encryption Or conventional / private-key / single-key sender and.
Chapter 2 Basic Encryption and Decryption (part B)
Lecture 1 Overview.
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
IT 221: Classical and Modern Encryption Techniques Lecture 2: Classical and Modern Encryption Techniques For Educational Purposes Only Revised: September.
Chapter 2 – Classical Encryption Techniques
3.1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 3 Traditional Symmetric-Key Ciphers.
Cryptography Week-6.
Lecture 2 Overview.
Security in Computing Cryptography (Introduction) Derived from Greek words: ‘Kruptos’ (hidden) and ‘graphein’ (writing.
Week 2 - Wednesday.  What did we talk about last time?  Encryption  Shift ciphers  Transposition ciphers.
Chapter 1 Introduction Cryptography-Principles and Practice Harbin Institute of Technology School of Computer Science and Technology Zhijun Li
Chapter 2 – Elementary Cryptography  Concepts of encryption  Cryptanalysis  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public.
Section 2.1: Shift Ciphers and Modular Arithmetic The purpose of this section is to learn about modular arithmetic, which is one of the fundamental mathematical.
Lec. 5 : History of Cryptologic Research II
Based on Applied Cryptography by Schneier Chapter 1: Foundations Dulal C. Kar.
ITMS – 3153 Information Systems Security
1 Chapter 2-1 Conventional Encryption Message Confidentiality.
Symmetric-Key Cryptography
Module :MA3036NI Cryptography and Number Theory Lecture Week 3 Symmetric Encryption-2.
9/03/15UB Fall 2015 CSE565: S. Upadhyaya Lec 2.1 CSE565: Computer Security Lecture 2 Basic Encryption & Decryption Shambhu Upadhyaya Computer Science &
CSCI 5857: Encoding and Encryption
Cryptography Lecture 2: Classic Ciphers Piotr Faliszewski.
Classical Cryptography I CS432 - Security in Computing Copyright © 2005, 2010 by Scott Orr and the Trustees of Indiana University.
Cryptography Lynn Ackler Southern Oregon University.
Cryptography Part 1: Classical Ciphers Jerzy Wojdyło May 4, 2001.
Elementary Cryptography  Concepts of encryption  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public key) Encryption (RSA)(RSA)
Traditional Symmetric-Key Ciphers
Computer Security Cryptography. Cryptography Now and Before  In the past – mainly used for confidentiality  Today –Still used for confidentiality –Data.
Basic Encryption & Decryption Codebreaking 101 Copyright © 2000 by the Trustees of Indiana University except as noted CRYPTOGRAPHY Encryption: a means.
Computer Science and Engineering Computer System Security CSE 5339/7339 Lecture 3 August 26, 2004.
TOTURIAL CRYPTOGRAPHY Ver :1. Things to learn about  Concepts of encryption  Cryptanalysis  Symmetric encryption  Asymmetric encryption  Protocols.
K. Salah1 Cryptography Module I. K. Salah2 Cryptographic Protocols  Messages should be transmitted to destination  Only the recipient should see it.
Intro to Cryptography Lesson Introduction
Introduction to Cryptography Lecture 8. Polyalphabetic Substitutions Definition: Let be different substitution ciphers. Then to encrypt the message apply.
Symmetric Cipher Model Plaintext input 1- encryption algorithm 2- secret key Encryption Cipher text output Cipher text input 1- Decryption algorithm 2-
Lecture 4 Page 1 CS 236 Online Basic Encryption Methods Substitutions –Monoalphabetic –Polyalphabetic Permutations.
Cryptography and Network Security Chapter 2
Network Security Lecture 13 Presented by: Dr. Munam Ali Shah.
EEC 688/788 Secure and Dependable Computing Lecture 3 Wenbing Zhao Department of Electrical and Computer Engineering Cleveland State University
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
Lecture 2 Overview. Cryptography Secret writing – Disguised data cannot be read, modified, or fabricated easily – Feasibility of complexity for communicating.
1 Classical Encryption Techniques. 2 Symmetric cipher model –Cryptography –Cryptanalysis Substitution techniques –Caesar cipher –Monoalphabetic cipher.
Chapter Two: Classic Cryptography
Prof. Wenguo Wang Network Information Security Prof. Wenguo Wang Tel College of Computer Science QUFU NORMAL UNIVERSITY.
Computer Security By Rubel Biswas. Introduction History Terms & Definitions Symmetric and Asymmetric Attacks on Cryptosystems Outline.
Department of Computer Science Chapter 5 Introduction to Cryptography Semester 1.
COMPUTER AND NETWORK SECURITY First of all, an introduction to the field of computer security and some of relevant issues are presented. Then, a background.
CRYPTOGRAPHY Cryptography is art or science of transforming intelligible message to unintelligible and again transforming that message back to the original.
@Yuan Xue Quick Review.
CRYPTOGRAPHY G REEK WORD MEANING “ SECRET WRITING ”
Substitution Ciphers.
CSE565: Computer Security Lecture 2 Basic Encryption & Decryption
Chapter 2 Basic Encryption and Decryption
Chapter-2 Classical Encryption Techniques.
Presentation transcript:

Chapter 2 Basic Encryption and Decryption

csci5233 computer security & integrity 2 Encryption / Decryption encrypted transmission AB plaintext ciphertext encryption decryption A: sender; B: receiver Transmission medium An interceptor (or intruder) may block, intercept, modify, or fabricate the transmission.

csci5233 computer security & integrity 3 Encryption / Decryption Encryption: A process of encoding a message, so that its meaning is not obvious. (= encoding, enciphering) Decryption: A process of decoding an encrypted message back into its original form. (= decoding, deciphering) A cryptosystem is a system for encryption and decryption.

csci5233 computer security & integrity 4 Plaintext / ciphertext P: plaintext C: ciphertext E: encryption D: decryption C = E (P) P = D (C) P = D ( E(P) )

csci5233 computer security & integrity 5 Cryptosystems Symmetric encryption: P = D (Key, E(Key,P) ) Asymmetric encryption: P = D (Key D, E(Key E,P) ) Symmetric cryptosystem: A cryptosystem that uses symmetric encryption. Asymmetric cryptosystem See Fig. 2-2 (p.23)

csci5233 computer security & integrity 6 Keys Use of a key provides additional security. Exposure of the encryption algorithm does not expose the future messages< as long as the key(s) are kept secret. c.f., keyless cipher

csci5233 computer security & integrity 7 Terminology Cryptography: The practice of using encryption to conceal text. (cryptographer) Cryptanalysis: The study of encryption and encrypted messages, with the goal of finding the hidden meanings of the messages. (cryptanalyst) Cryptology = cryptography + cryptanalysis

csci5233 computer security & integrity 8 Cryptanalysis A cryptanalyst may work with various data (intercepted messages, data items known or suspected to be in a ciphertext message), known encryption algorithms, mathematical or statistical tools and techniques, properties of languages, computers, and plenty of ingenuity and luck. 1.Attempt to break a single message 2.Attempt to recognize patterns in encrypted messages 3.Attempt to find general weakness in an encryption algorithm

csci5233 computer security & integrity 9 Breakability of an encryption An encryption algorithm may be breakable, meaning that given enough time and data, an analyst could determine the algorithm. Suppose there exists possible decipherments for a given cipher scheme. A computer performs operations per second. Finding the decipherment would require seconds (or roughly years).

csci5233 computer security & integrity 10 Modular arithmetic A.. Z: Example: p.24 C = P mod 26

csci5233 computer security & integrity 11 Two forms of encryption Substitutions One letter is exchanged for another Examples: monoalphabetic substitution ciphers, polyalphabetic substitution ciphers Transpositions (= permutations) The order of the letters is rearranged Examples: columnar transpositions

csci5233 computer security & integrity 12 Substitutions Caesar cipher: Each letter is translated to the letter a fixed number of letters after it in the alphabet. C i = E(P i ) = P i + 3 Advantage: simple Weakness

csci5233 computer security & integrity 13 Cryptanalysis of the Caesar Cipher Exercise (p.26): Decrypt the encrypted message. Deduction based on guesses versus frequency distribution (p.28)

csci5233 computer security & integrity 14 Other monoalphabetic substitutions Using permutation Pi (lambda) = 25 – lambda Weakness: Double correspondence E(F) = u and D(u) = F Using a key A key is a word that controls the ciphering. p.27

csci5233 computer security & integrity 15 Complexity of monoalphabetic substitutions Monoalphabetic substitutions amount to table lookups. The time to encrypt a message of n characters is proportional to n.

csci5233 computer security & integrity 16 Frequency distribution Table 2-1 (p.29) shows the counts and relative frequencies of letters in English. Frequencies in a sample cipher: Table 2-2 (p.30) Compare the sample cipher against the normal frequency distribution: Fig. 2-4

csci5233 computer security & integrity 17 Polyalphabetic substitutions By combining distributions that are high with the ones that are low Using multiple substitution tables Example (p.32): table for odd positions, table for even positions

csci5233 computer security & integrity 18 Vigenère Tableaux Table 2-5: p.34 Example: p.35 Exercise: Complete the encryption of the original message. Exercise: Decipher the encrypted message using the key (‘juliet’)

csci5233 computer security & integrity 19 Cryptanalysis of Polyalphabetic substitutions The Kasiski method: a method to find the number of alphabets used for encryption Works on duplicate fragments in the ciphertext The distance between the repeated patterns must be a multiple of the keyword length

csci5233 computer security & integrity 20 Steps for the Kasiski method p.36 Initial find + verification using frequency distribution

csci5233 computer security & integrity 21 Index of coincidence A measure of the variation between frequencies in a distribution To measure the nonuniformity of a distribution To rate how well a particular distribution matches the distribution of letters in English RFreq versus Prob (p.38) Example: –In the English language, RFreq a = Prob a = 7.49 (from Table 2.1) –In the sample cipher in Table 2-2 (p.30): RFreq a = 0  Prob a

csci5233 computer security & integrity 22 Index of Coincidence Measure of roughness (or the variance): a measure of the size of the peaks and valleys (See Fig. 2-6, p.38) The var of a perfectly flat distribution = 0. The variance can be estimated by counting the number of pairs of identical letters and dividing by the total number of pairs possible –Example (Given 200 letters): 60 / 100

csci5233 computer security & integrity 23 Index of Coincidence IC (index of coincidence): a way to approximate variance from observed data (p.39) (perfect)  IC  (English)

csci5233 computer security & integrity 24 Combined use of IC with Kasiski method Bottom of p.39 All the subsets from the Kasiski method, if the key length was correct, should have distributions close to

csci5233 computer security & integrity 25 Analyzing a polyalphabetic cipher 1. Use the Kasiski method to predict the likely numbers of enciphering alphabets. 2. Compute the IC to validate the predictions 3. (When 1 and 2 show promises) Generate subsets and calculate IC’s for the subsets

csci5233 computer security & integrity 26 The “Perfect” Substitution Cipher Use an infinite nonrepeating sequence of alphabets A key with an infinite number of nonrepeating digits Examples: one-time pads, the Vernam cipher, …

csci5233 computer security & integrity 27 Vernam Cipher Sample function: c = ( p + random( ) ) mod 26 Example: p.42 Binary Vernam Cipher p.43: How would you decipher a ciphertext encrypted by Binary Vernam Cipher? Ans.: p = (c – random( ) ) mod 26 Example (p.42): c = 19 (‘t’), random( ) = 76 p = (19-76) mod 26 = 21

csci5233 computer security & integrity 28 Random Number Generators A pseudo-random number generator is a computer program that generates numbers from a predictable, repeating sequence. Example: The linear congruential random number generator r i+1 = (a * r i + b) mod n Note: 12 is congruent to 2 (modulo 5), since (12-2) mod 5 = 0 Problem? Its dependability; probable word attack

csci5233 computer security & integrity 29 The six frequent letters P.45 A correction: (E, e)  i How to use the table ‘inside out’?

csci5233 computer security & integrity 30 Dual-Message Entrapment P.46 Encipher two messages at once One message is real; the other is the dummy. Both the sender and the receiver know the dummy message (the key). The key cannot be distinguished from the real message.

csci5233 computer security & integrity 31 Summary Substitutions and permutations together form a basis for the most widely used encryption algorithms  Chap. 3. Next: Pf, Ch 2 (part b)