Scott CH Huang COM 5336 Cryptography Lecture 1 Scott CH Huang COM 5336 Cryptography Lecture 1 Introduction.

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.
CS 6262 Spring 02 - Lecture #7 (Tuesday, 1/29/2002) Introduction to Cryptography.
Cryptology  Terminology  plaintext - text that is not encrypted.  ciphertext - the output of the encryption process.  key - the information required.
Lecture 2.1: Private Key Cryptography -- I CS 436/636/736 Spring 2013 Nitesh Saxena.
Classical Cryptography
CSE331: Introduction to Networks and Security Lecture 17 Fall 2002.
1 Day 04- Cryptography Acknowledgements to Dr. Ola Flygt of Växjö University, Sweden for providing the original slides.
Chapter 2 – Classical Encryption Techniques. Classical Encryption Techniques Symmetric Encryption Or conventional / private-key / single-key sender and.
CS1001 Lecture 24. Overview Encryption Encryption Artificial Intelligence Artificial Intelligence Homework 4 Homework 4.
CS426Fall 2010/Lecture 21 Computer Security CS 426 Lecture 2 Cryptography: Terminology & Classic Ciphers.
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
Cryptographic Algorithms Course information General Concepts Introductory examples Terminology Classical cryptography Cryptanalysis.
Computer Security CS 426 Lecture 3
Classical Encryption Techniques
L1.1. An Introduction to Classical Cryptosystems Rocky K. C. Chang, February 2013.
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.
3.1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 3 Traditional Symmetric-Key Ciphers.
Cryptography Week-6.
Tonga Institute of Higher Education Design and Analysis of Algorithms IT 254 Lecture 9: Cryptography.
Chapter 2 Basic Encryption and Decryption. csci5233 computer security & integrity 2 Encryption / Decryption encrypted transmission AB plaintext ciphertext.
Classical Encryption Techniques
3.1 SERVICES AND MECHANISMS SERVICES AND MECHANISMS The International Telecommunication Union- Telecommunication Standardization Section (ITU-T) provides.
A Technical Seminar Presentation CLASSICAL CRYPTOGRAPHY
Cis 4930 Introduction to cryptography
Lec. 5 : History of Cryptologic Research II
Introduction to Cryptography
Topic 21 Cryptography CS 555 Topic 2: Evolution of Classical Cryptography CS555.
Cryptography and Network Security (CS435) Part Two (Classic Encryption Techniques)
Day 18. Concepts Plaintext: the original message Ciphertext: the transformed message Encryption: transformation of plaintext into ciphertext Decryption:
Network Security Lecture 12 Presented by: Dr. Munam Ali Shah.
CIT 380: Securing Computer SystemsSlide #1 CIT 380: Securing Computer Systems Classical Cryptography.
 Classic Crypto  Slides based on those developed by Dr. Lawrie Brown at the Australian Defence Force Academy, University College, UNSW  See
1 Chapter 2-1 Conventional Encryption Message Confidentiality.
Symmetric-Key Cryptography
Module :MA3036NI Cryptography and Number Theory Lecture Week 3 Symmetric Encryption-2.
2002 Networking Operating Systems (CO32010) 1. Operating Systems 2. Processes and scheduling 3.
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
Introduction to Ciphers Breno de Medeiros. Cipher types From “Cipher”, Wikipedia article.
Cryptography Part 1: Classical Ciphers Jerzy Wojdyło May 4, 2001.
Cryptography (Traditional Ciphers)
1 Cryptanalysis Four kinds of attacks (recall) The objective: determine the key ( Herckhoff principle ) Assumption: English plaintext text Basic techniques:
Traditional Symmetric-Key Ciphers
Computer Security Cryptography. Cryptography Now and Before  In the past – mainly used for confidentiality  Today –Still used for confidentiality –Data.
Data Security and Encryption (CSE348) 1. Lecture # 3 2.
1 Intrusion Detection Auditing, Watermarking Dec 7, 2006 Lecture 10 IS 2150 / TEL 2810 Introduction to Security.
K. Salah1 Cryptography Module I. K. Salah2 Cryptographic Protocols  Messages should be transmitted to destination  Only the recipient should see it.
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.
Network Security Lecture 13 Presented by: Dr. Munam Ali Shah.
Lecture 2 (Chapter 2) Classical Encryption Techniques Prepared by Dr. Lamiaa M. Elshenawy 1.
CS526Topic 2: Classical Cryptography1 Information Security CS 526 Topic 2 Cryptography: Terminology & Classic Ciphers.
1 Classical Encryption Techniques. 2 Symmetric cipher model –Cryptography –Cryptanalysis Substitution techniques –Caesar cipher –Monoalphabetic cipher.
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.
@Yuan Xue CS 285 Network Security Cryptography Overview and Classical Encryption Algorithms Fall 2012 Yuan Xue.
Lecture 3 Page 1 CS 236 Online Basic Encryption Methods Substitutions –Monoalphabetic –Polyalphabetic Permutations.
@Yuan Xue Quick Review.
Substitution Ciphers.
Chapter 2 Basic Encryption and Decryption
Taehyung Kim HPC Lab. POSTECH
A Technical Seminar Presentation CLASSICAL CRYPTOGRAPHY
Traditional Symmetric-Key Ciphers
Symmetric Encryption or conventional / private-key / single-key
Presentation transcript:

Scott CH Huang COM 5336 Cryptography Lecture 1 Scott CH Huang COM 5336 Cryptography Lecture 1 Introduction

Scott CH Huang 2 Who’s who? COM 5336 Cryptography Lecture 1

Scott CH Huang COM 5336 Cryptography Lecture 1 Outline What is Cryptography? Steganography Cryptography: past, present and future Classical Cryptography – Shift cipher – Simple substitution cipher – Poly-alphabetic substitution cipher One-time pad

Scott CH Huang COM 5336 Cryptography Lecture 1 What is Cryptography? The American Heritage Dictionary: – “The art or process of writing in or deciphering secret code.” Webster: – “ The science or study the techniques of secret writing. ” More generally, – “A science which studies how to provide communication channels with secrecy and/or authenticity properties.” Communication channels: – Network, hard drive, CD-ROM, etc.

Scott CH Huang COM 5336 Cryptography Lecture 1 Steganography Dear George; Greetings to all at Oxford. Many thanks for your letter and for the summer examination package. All Entry Forms and Fees Forms should be ready for final dispatch to the Syndicate by Friday 20th or at the very latest, I’m told by the 21st. Admin has improved here, thought there’s room for improvement still, just give us all two or three more years and we’ll really show you! Please don’t let these wretched 16+ proposals destroy your basic O and A pattern. Certainly this sort of change, if implemented immediately, would bring chaos. Sincerely yours;

Scott CH Huang COM 5336 Cryptography Lecture 1 Steganography (cont’d) Susan eats truffles. Under pressure, that helps everything before owning Major Bullwinkle.

Scott CH Huang COM 5336 Cryptography Lecture 1 Steganography (cont’d) Fishing freshwater bends and saltwater coasts rewards anyone feeling stressed. Resourceful anglers usually find masterful leapers fun and admit swordfish rank overwhelming anyday.

Scott CH Huang COM 5336 Cryptography Lecture 1 Cryptography: Past, Present, and Future Old days – Classical cryptography – Essentially secret writing (encryption) Today – Conventional Cryptography (symmetric key) – Public Key cryptography (asymmetric key) – Other cryptographic algorithms and schemes proof of knowledge, digital signature, message authentication, secret sharing, etc. Future – Quantum Cryptography

Scott CH Huang COM 5336 Cryptography Lecture 1 Classical Cryptography: Two Main Techniques 1.Shift 2.Substitution −Mono-alphabetic substitution −Poly-alphabetic substitution

Scott CH Huang COM 5336 Cryptography Lecture 1 XFMDPNFUPDJUZVOJWFSTJUZPGIPOHLPOHWELCOMETOCITYUNIVERSITYOFHONGKONGAIPGSQIXSGMXCYRMZIVWMXCSJLSRKOSRKZHOFRPHWRFLWBXQLYHUVLWBRIKRQJNRQJ YGNEQOGVQEKVAWPKXGTUKVAQHJQPIMQPI Shift Cipher ABCDEFGHIJKLMNOPQRSTUVWXYZ WXYZABCDEFGHIJKLMNOPQRSTUVWXYZ Ciphertext : Plaintext: AIPGSQIXSGMXCYRMZIVWMXCSJLSRKOSRK  Total number of possible shifts = 26 …can you write a computer program to automate this cracking machine?… WXYZABCDEFGHIJKLMNOPQRSTUVWXYZ

Scott CH Huang COM 5336 Cryptography Lecture 1 Shift Cipher Famous shift cipher: Caesar Cipher −Shift by 3 letters −reputedly used by Julius Caesar (100 – 44 B.C.) Plaintext:I CAME I SAW I CONQUERED Ciphertext:L FDPH L VDZ L FRQTXHUHG A shift cipher can also be described as Encryption E K (x) = x + K mod 26 Decryption D K (x) = x - K mod 26 for English alphabet by setting up a correspondence between alphabetic characters and residues modulo 26. −K is the Key −K=3 in Caesar Cipher

Scott CH Huang COM 5336 Cryptography Lecture 1 Security Strength of a Shift Cipher Only have 26 possible shifts Brute-force Attack : simply try each possible shift in turn - a.k.a. exhaustive key search Example: Ciphertext –mjaiamwlxsvitpegipixxivw Trial 1lizhzlvkwruhsodfhohwwhuv (shift backward by 1) Trial 2khygykujvotgrncegngvvgtu (shift backward by 2) Trial 3jgxfxjtiupsfombdfmfuufst (shift backward by 3) Plaintext -ifwewishtoreplaceletters (shift backward by 4) Hence K=4. The major problem of shift ciphers: “the key space is too small against brute-force attack” The complexity of brute-force attack is O(n).

Scott CH Huang COM 5336 Cryptography Lecture 1 Simple Substitution DEPARTMENTOFCOMPUTERSCIENCE A B C D E F G H I J K L M N O P Q R S T U V W X Y Z EIMBULJIWLNYANJMVLIURAHIWAI A key is a random permutation of the alphabetic characters. E.g. What’s the ciphertext of “ solutionsoffinalexam ”?

Scott CH Huang COM 5336 Cryptography Lecture 1 Simple Substitution Total number of possible permutations 26! 26! = 403,291,461,126,605,635,584,000,000 (i.e. 27 digits) Maybe… also write a computer program to try them all exhaustively… (so- called Brute-force Attack) Calculation: suppose we have one million 3GHz PCs can try 3 billion permutations per second, the machine will take 4263 years to try all 26! permutations. Question: any better cracking algorithm?

Scott CH Huang COM 5336 Cryptography Lecture 1 Character Frequency Attack (Statistical Attack) Brute-force attack against simple substitution becomes less efficient for large alphabet size. However, simple substitution does not change relative letter frequencies. letterprobabilityletterprobability A.082N.067 B.015O.075 C.028P.019 D.043Q.001 E.127R.060 F.022S.063 G.020T.091 H.061U.028 I.070V.010 J.002W.023 K.008X.001 L.040Y.020 M.024Z.001 Character Frequency Attack in most languages, letters are not equally common in English, e and t are by far the most common letters Probability of occurrences of the 26 English letters (obtained by Beker and Piper)

Scott CH Huang COM 5336 Cryptography Lecture 1 Character Frequency Attack (Statistical Attack) May also be useful to consider sequences of two or three consecutive letters called digrams and trigrams, respectively. e.g. common diagrams (in decreasing order): TH, HE, IN, ER, AN, RE, ED, ON, ES, ST, EN, AT, TO, NT, HA, ND, OU, EA, NG, AS, OR, … e.g. common trigrams (in decreasing order): THE, ING, AND, HER, ERE, ENT, THA, NTH, WAS, …

Scott CH Huang COM 5336 Cryptography Lecture 1 May also be useful to consider sequences of two or three consecutive letters called digrams and trigrams, respectively. e.g. common diagrams (in decreasing order): TH, HE, IN, ER, AN, RE, ED, ON, ES, ST, EN, AT, TO, NT, HA, ND, OU, EA, NG, AS, OR, … e.g. common trigrams (in decreasing order): THE, ING, AND, HER, ERE, ENT, THA, NTH, WAS, … Cryptanalysis of The Substitution Cipher Exercise: Ciphertext obtained from a substitution cipher What’s the message?

Scott CH Huang COM 5336 Cryptography Lecture 1 Polyalphabetic Substitution Ciphers In both the Shift Cipher and the Substitution Cipher, once a key is chosen, each alphabetic character is mapped to a unique alphabetic character – monoalphabetic. −Small key space (O(n) for Shift Cipher) −Vulnerable to statistical attacks (Substitution Cipher). Alternative: Polyalphabetic Substitution Ciphers −We want large key space and less vulnerable to statistical attacks Approach: for different location or different time, same letter is to be substituted by different letter.

Scott CH Huang COM 5336 Cryptography Lecture 1 Vigenère Cipher Invented in the 16 th century A kind of poly-alphabetic substitution cipher Using the correspondence A  0, B  1, …, Z  25. Keyword:CIPHER  (2, 8, 15, 7, 4, 17) Plaintext:thiscryptosystemisnotsecure Ciphertext:VPXZGIAXIVWPUBTTMJPWIZITWZT

Scott CH Huang COM 5336 Cryptography Lecture 1 Vigenère Cipher and Enigma Number of possible keywords of length m = 26 m. Much larger than that of a simple substitution cipher. An alphabetic character of a plaintext can be mapped to one of m possible alphabetic characters (assuming that the keyword contains m distinct characters). In general, cryptanalysis is much more difficult for polyalphabetic than for monoalphabetic cryptosystems. Rotor Machines In the 1920s, various mechanical encryption devcies were invented to automate the process of encryption. A rotor machine has a keyboard and a series of rotors, and implements a version of the Vigenère cipher. The best-known rotor device is the Enigma, used by the Germans during World War II.

Scott CH Huang COM 5336 Cryptography Lecture 1 Kasiski Test (1863) Idea: any two identical strings will be encrypted to the same ciphertext if they are km positions apart where m is the keyword length and k is a positive integer. Two Steps of Attack: −Find the keyword length −Conduct statistical attack An Example of Attack −Look for trigrams that are identical −Compute the distance between them, d 1, d 2, … −Let m’ be a divisor of gcd(d 1, d 2, …) −Write the ciphertext in a rectangular array with m’ columns, then statistical attack can be used on each column

Scott CH Huang COM 5336 Cryptography Lecture 1 One-Time Pad Polyalphabetic substitution with the keyword as long as the plaintext and the keyword has no statistical relationship to the plaintext. Vernam Cipher (1918) −Works on binary string rather than letters −C i = P i  K i, where K i is chosen randomly −The only cryptographic system that can be proved to be unconditionally secure −Can be shown to be information theoretically secure.

Scott CH Huang COM 5336 Cryptography Lecture 1 Weakness of One-time Pad Malleable: Provides secrecy but not authentication. Keys must NOT be reused: – cannot withstand Known Plaintext Attack – depending on known information about plaintexts, Eve can make use of C 1  C 2 = (M 1  K)  (M 2  K) = M 1  M 2 to figure out both messages Generating random bits – radioactive decay – noisy diode – flipping coins