Chapter 2 Basic Encryption and Decryption

Slides:



Advertisements
Similar presentations
CLASSICAL ENCRYPTION TECHNIQUES
Advertisements

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
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
Cryptography Week-6.
Chapter 2 Basic Encryption and Decryption. csci5233 computer security & integrity 2 Encryption / Decryption encrypted transmission AB plaintext ciphertext.
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 2 – Elementary Cryptography  Concepts of encryption  Cryptanalysis  Symmetric (secret key) Encryption (DES & AES)(DES & AES)  Asymmetric (public.
Elementary Cryptography
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 &
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.
Cryptography and Network Security Chapter 2
Network Security Lecture 13 Presented by: Dr. Munam Ali Shah.
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.
Lecture 3 Page 1 CS 236 Online Basic Encryption Methods Substitutions –Monoalphabetic –Polyalphabetic Permutations.
@Yuan Xue Quick Review.
CRYPTOGRAPHY G REEK WORD MEANING “ SECRET WRITING ”
Substitution Ciphers.
CSE565: Computer Security Lecture 2 Basic Encryption & Decryption
Cryptography and Network Security
Basic Encryption Methods
Chapter-2 Classical Encryption Techniques.
Taehyung Kim HPC Lab. POSTECH
Cryptography.
EEC 688/788 Secure and Dependable Computing
Chapter 3:Cryptography (16M)
Cryptography II Jagdish S. Gangolly School of Business
PART VII Security.
Basic Encryption Methods
Symmetric Encryption or conventional / private-key / single-key
Presentation transcript:

Chapter 2 Basic Encryption and Decryption

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

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

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

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

csci5233 computer security & integrity 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

csci5233 computer security & integrity 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

csci5233 computer security & integrity 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. Attempt to break a single message Attempt to recognize patterns in encrypted messages Attempt to find general weakness in an encryption algorithm csci5233 computer security & integrity

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 1030 possible decipherments for a given cipher scheme. A computer performs 1010 operations per second. Finding the decipherment would require 1020 seconds (or roughly 1012 years). csci5233 computer security & integrity

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

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

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

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

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

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

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

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

csci5233 computer security & integrity 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

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

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

csci5233 computer security & integrity 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, RFreqa = Proba = 7.49 (from Table 2.1) In the sample cipher in Table 2-2 (p.30): RFreqa = 0  Proba csci5233 computer security & integrity

csci5233 computer security & integrity 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

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

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 0.068. csci5233 computer security & integrity

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

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

csci5233 computer security & integrity 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

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 ri+1 = (a * ri + 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

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

Dual-Message Entrapment 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

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