SlideShare a Scribd company logo
Overview of Cryptographic 
Techniques 
Hector M Lugo-Cordero 
CIS 4361 
Secure Operating System Administration 
1
2 
Resources Used 
• Lecture slides from Dr Ratan Guha CNT 
6519 Wireless Security Forensics 
• Cryptography and Network Security, 
Fourth Edition, by William Stallings 
• Lecture slides for the textbook by Lawrie 
Brown 
• Lecture slides by Henric Johnson,Blekinge 
Institute of Technology, Sweden
3 
OOuuttlliinnee 
• Some Basic Terminology 
• Conventional Encryption Principles 
• Characteristics of Cryptographic 
Techniques 
• Symmetric Encryption 
• Classical Symmetric Encryption 
Algorithms 
• Modern Symmetric Encryption 
Techniques
4 
Some Basic Terminology 
• plaintext - original message 
• ciphertext - coded message 
• cipher - algorithm for transforming plaintext to ciphertext 
• key - info used in cipher known only to sender/receiver 
• encipher (encrypt) - converting plaintext to ciphertext 
• decipher (decrypt) - recovering ciphertext from plaintext 
• cryptography - study of encryption principles/methods 
• cryptanalysis (codebreaking) - study of principles/ 
methods of deciphering ciphertext without knowing key 
• cryptology - field of both cryptography and cryptanalysis
5 
CCoonnvveennttiioonnaall EEnnccrryyppttiioonn 
PPrriinncciipplleess 
• An encryption scheme has five ingredients: 
– Plaintext 
– Encryption algorithm 
– Secret Key 
– Ciphertext 
– Decryption algorithm 
• Security depends on the secrecy of the key, not 
the secrecy of the algorithm
6 
Characteristics ooff CCrryyppttooggrraapphhiicc 
TTeecchhnniiqquueess 
• Classified along three independent dimensions: 
– The type of operations used for transforming plaintext 
to ciphertext 
– The number of keys used 
• symmetric (single key) 
• asymmetric (two-keys, or public-key encryption) 
– The way in which the plaintext is processed
7 
Symmetric Encryption 
• or conventional / private-key / single-key 
• sender and recipient share a common key 
• all classical encryption algorithms are 
private-key 
• was only type prior to invention of public-key 
in 1970’s 
• and by far most widely used
8 
Symmetric Cipher Model
9 
Requirements 
• two requirements for secure use of 
symmetric encryption: 
– a strong encryption algorithm 
– a secret key known only to sender / receiver 
• mathematically have: 
Y = EK(X) [= E(K, X) ] 
X = DK(Y) [= D(K, Y) ] 
• assume encryption algorithm is known 
• implies a secure channel to distribute key
10 
Brute Force Search 
• always possible to simply try every key 
• most basic attack, proportional to key size 
• assume either know / recognize plaintext 
Key Size (bits) Number of Alternative 
Keys 
Time required at 1 
decryption/μs 
Time required at 106 
decryptions/μs 
32 232 = 4.3 ´ 109 231 μs = 35.8 minutes 2.15 milliseconds 
56 256 = 7.2 ´ 1016 255 μs = 1142 years 10.01 hours 
128 2128 = 3.4 ´ 1038 2127 μs = 5.4 ´ 1024 years 5.4 ´ 1018 years 
168 2168 = 3.7 ´ 1050 2167 μs = 5.9 ´ 1036 years 5.9 ´ 1030 years 
26 characters 
(permutation) 
26! = 4 ´ 1026 2 ´ 1026 μs = 6.4 ´ 1012 years 6.4 ´ 106 years
11 
Classical Substitution Ciphers 
• where letters of plaintext are replaced by 
other letters or by numbers or symbols 
• or if plaintext is viewed as a sequence of 
bits, then substitution involves replacing 
plaintext bit patterns with ciphertext bit 
patterns
12 
Caesar Cipher 
• earliest known substitution cipher 
• by Julius Caesar 
• first attested use in military affairs 
• replaces each letter by 3rd letter after 
• example: 
meet me after the toga party 
PHHW PH DIWHU WKH WRJD SDUWB
13 
Caesar Cipher 
• can define transformation as: 
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 
D E F G H I J K L M N O P Q R S T U V W X Y Z A B C 
• mathematically give each letter a number 
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 
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 
• then have Caesar cipher as: 
c = E(p) = (p + k) mod (26) 
p = D(c) = (c – k) mod (26)
14 
Monoalphabetic Cipher 
• rather than just shifting the alphabet 
• could shuffle (jumble) the letters arbitrarily 
• each plaintext letter maps to a different random 
ciphertext letter 
• hence key is 26 letters long 
Plain: abcdefghijklmnopqrstuvwxyz 
Cipher: DKVQFIBJWPESCXHTMYAUOLRGZN 
Plaintext: ifwewishtoreplaceletters 
Ciphertext: WIRFRWAJUHYFTSDVFSFUUFYA
15 
Playfair Cipher 
• not even the large number of keys in a 
monoalphabetic cipher provides security 
• one approach to improving security was to 
encrypt multiple letters 
• the Playfair Cipher is an example 
• invented by Charles Wheatstone in 1854, 
but named after his friend Baron Playfair
16 
Playfair Key Matrix 
• a 5X5 matrix of letters based on a 
keyword 
• fill in letters of keyword (minus duplicates) 
• fill rest of matrix with other letters 
• eg. using the keyword MONARCHY 
M O N A R 
C H Y B D 
E F G I/J K 
L P Q S T 
U V W X Z
17 
Encrypting and Decrypting 
• plaintext is encrypted two letters at a time 
1. if a pair is a repeated letter, insert filler like 'X’ 
(low probability of appearance in language) 
2. if both letters fall in the same row, replace 
each with letter to right (wrapping back to start 
from end) 
3. if both letters fall in the same column, replace 
each with the letter below it (again wrapping to 
top from bottom) 
4. otherwise each letter is replaced by the letter 
in the same row and in the column of the other 
letter of the pair 
Wireless Wi re le sx sz XG MK UL XA XT
18 
Polyalphabetic Ciphers 
• polyalphabetic substitution ciphers 
• A set of related monoalphabetic substitution rules is 
used 
• use a key to select which alphabet is used for each 
letter of the message 
• use each alphabet in turn 
• repeat from start after end of key is reached 
• make cryptanalysis harder with more alphabets to 
guess and flatter frequency distribution 
Key: deceptive 3 4 2 4 15 19 8 21 4 
plaintext: wireless 22 8 17 4 11 4 18 18 
ciphertext: zmtiaxao 25 12 19 8 26 23 26 39
19 
Vigenère Cipher 
• simplest polyalphabetic substitution cipher 
• effectively multiple caesar ciphers 
• key is multiple letters long K = k1 k2 ... kd 
• ith letter specifies ith alphabet to use 
• use each alphabet in turn 
• repeat from start after d letters in message 
• decryption simply works in reverse
20 
Example of Vigenère Cipher 
• write the plaintext out 
• write the keyword repeated above it 
• use each key letter as a caesar cipher key 
• encrypt the corresponding plaintext letter 
• eg using keyword deceptive 
key: deceptivedeceptivedeceptive 
plaintext: wearediscoveredsaveyourself 
ciphertext:ZICVTWQNGRZGVTWAVZHCQYGLMGJ
Vernam Cipher and One-time 
Pad 
• Keyword is as long as the plaintext and 
has no statistical relationship to it. 
• Vernam system works on binary data with 
ith bit of text exclusive ored with ith bit of 
key to produce ith bit of cipher 
• In one one-time pad key is used only once 
• This scheme is unbreakable 
21
Transposition Cipher 
• Mapping is performed by some sort of 
permutation on the plaintext letters. 
• Example: Rail fence of depth 2 
text : meet me after the toga party 
m e m a t r h t g p r y 
e t e f e t e o a a t 
cipher: 
MEMATRHTGPRYETEFETEOAAT 
Rail fence of depth 2 22
Classical Ciphers 
• Caesar Cipher 
• Monoalphabetic Cipher 
• Playfair Cipher 
• Polyphabetic Cipher 
• Vigenère Cipher 
• Vernam Cipher and One-time Pad 
• Transposition Cipher 
Cryptography -Part -I 23
Modern Block Ciphers 
• now look at modern block ciphers 
• one of the most widely used types of 
cryptographic algorithms 
• provide secrecy /authentication services 
• focus on DES (Data Encryption Standard) 
• to illustrate block cipher design principles
Block vs Stream Ciphers 
• block ciphers process messages in 
blocks, each of which is then en/decrypted 
• like a substitution on very big characters 
– 64-bits or more 
• stream ciphers process messages a bit or 
byte at a time when en/decrypting 
• many current ciphers are block ciphers 
• broader range of applications
Block Cipher Principles 
• most symmetric block ciphers are based on a 
Feistel Cipher Structure 
• needed since must be able to decrypt ciphertext 
to recover messages efficiently 
• block ciphers look like an extremely large 
substitution 
• would need table of 264 entries for a 64-bit block 
• instead create from smaller building blocks 
• using idea of a product cipher
Ideal Block Cipher
Claude Shannon and Substitution- 
Permutation Ciphers 
• Claude Shannon introduced idea of substitution-permutation 
(S-P) networks in 1949 paper 
• form basis of modern block ciphers 
• S-P nets are based on the two primitive 
cryptographic operations seen before: 
– substitution (S-box) 
– permutation (P-box) 
• provide confusion & diffusion of message & key
Confusion and Diffusion 
• cipher needs to completely obscure 
statistical properties of original message 
• a one-time pad does this 
• more practically Shannon suggested 
combining S & P elements to obtain: 
• diffusion – dissipates statistical structure 
of plaintext over bulk of ciphertext 
• confusion – makes relationship between 
ciphertext and key as complex as possible
Feistel Cipher Structure 
• Horst Feistel devised the feistel cipher 
– based on concept of invertible product cipher 
• partitions input block into two halves 
– process through multiple rounds which 
– perform a substitution on left data half 
– based on round function of right half & subkey 
– then have permutation swapping halves 
• implements Shannon’s S-P net concept
Feistel Cipher Structure
Feistel Cipher Design Elements 
• block size 
• key size 
• number of rounds 
• subkey generation algorithm 
• round function 
• fast software en/decryption 
• ease of analysis
Feistel Cipher Encryption & Decryption

More Related Content

What's hot

Block Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption StandardBlock Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption Standard
Dr.Florence Dayana
 
Cryptography
CryptographyCryptography
Cryptography
Jens Patel
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network securitypatisa
 
Encryption algorithms
Encryption algorithmsEncryption algorithms
Encryption algorithms
trilokchandra prakash
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to Cryptography
Md. Afif Al Mamun
 
Cryptography
CryptographyCryptography
Cryptography
EmaSushan
 
6. cryptography
6. cryptography6. cryptography
6. cryptography7wounders
 
Cryptography
CryptographyCryptography
Cryptography
jayashri kolekar
 
Encryption ppt
Encryption pptEncryption ppt
Encryption ppt
Anil Neupane
 
Cryptography
CryptographyCryptography
Cryptography
Rutuja Solkar
 
Classical Encryption Techniques
Classical Encryption TechniquesClassical Encryption Techniques
Classical Encryption Techniques
university of education,Lahore
 
Fundamentals of cryptography
Fundamentals of cryptographyFundamentals of cryptography
Fundamentals of cryptography
Hossain Md Shakhawat
 
Encryption And Decryption
Encryption And DecryptionEncryption And Decryption
Encryption And DecryptionNA
 
Block cipher modes of operation
Block cipher modes of operation Block cipher modes of operation
Block cipher modes of operation
harshit chavda
 
Cryptography and Network Security
Cryptography and Network SecurityCryptography and Network Security
Cryptography and Network Security
Ramki M
 
Cryptography
CryptographyCryptography
Cryptography
CryptographyCryptography
Cryptography
Shivanand Arur
 
Transposition cipher
Transposition cipherTransposition cipher
Transposition cipher
Antony Alex
 
Cryptography ppt
Cryptography pptCryptography ppt
Cryptographic algorithms
Cryptographic algorithmsCryptographic algorithms
Cryptographic algorithms
Anamika Singh
 

What's hot (20)

Block Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption StandardBlock Ciphers and the Data Encryption Standard
Block Ciphers and the Data Encryption Standard
 
Cryptography
CryptographyCryptography
Cryptography
 
Cryptography and network security
Cryptography and network securityCryptography and network security
Cryptography and network security
 
Encryption algorithms
Encryption algorithmsEncryption algorithms
Encryption algorithms
 
Introduction to Cryptography
Introduction to CryptographyIntroduction to Cryptography
Introduction to Cryptography
 
Cryptography
CryptographyCryptography
Cryptography
 
6. cryptography
6. cryptography6. cryptography
6. cryptography
 
Cryptography
CryptographyCryptography
Cryptography
 
Encryption ppt
Encryption pptEncryption ppt
Encryption ppt
 
Cryptography
CryptographyCryptography
Cryptography
 
Classical Encryption Techniques
Classical Encryption TechniquesClassical Encryption Techniques
Classical Encryption Techniques
 
Fundamentals of cryptography
Fundamentals of cryptographyFundamentals of cryptography
Fundamentals of cryptography
 
Encryption And Decryption
Encryption And DecryptionEncryption And Decryption
Encryption And Decryption
 
Block cipher modes of operation
Block cipher modes of operation Block cipher modes of operation
Block cipher modes of operation
 
Cryptography and Network Security
Cryptography and Network SecurityCryptography and Network Security
Cryptography and Network Security
 
Cryptography
CryptographyCryptography
Cryptography
 
Cryptography
CryptographyCryptography
Cryptography
 
Transposition cipher
Transposition cipherTransposition cipher
Transposition cipher
 
Cryptography ppt
Cryptography pptCryptography ppt
Cryptography ppt
 
Cryptographic algorithms
Cryptographic algorithmsCryptographic algorithms
Cryptographic algorithms
 

Viewers also liked

Cipher techniques
Cipher techniquesCipher techniques
Cipher techniquesMohd Arif
 
Cryptography
CryptographyCryptography
Cryptography
Sidharth Mohapatra
 
Cryptanalysis - basic ciphers and a bit more
Cryptanalysis - basic ciphers and a bit moreCryptanalysis - basic ciphers and a bit more
Cryptanalysis - basic ciphers and a bit more
Things Lab
 
Cryptography
CryptographyCryptography
Cryptography
herrberk
 
Biometric technology
Biometric technologyBiometric technology
Biometric technologyDharmik
 
Substitution Cipher
Substitution CipherSubstitution Cipher
Substitution Cipher
Agung Julisman
 
Multi modal biometric system
Multi modal biometric systemMulti modal biometric system
Multi modal biometric system
Aalaa Khattab
 
5. message authentication and hash function
5. message authentication and hash function5. message authentication and hash function
5. message authentication and hash function
Chirag Patel
 
Biometrics/fingerprint sensors
Biometrics/fingerprint sensorsBiometrics/fingerprint sensors
Biometrics/fingerprint sensors
Jeffrey Funk
 
5 Cryptography Part1
5 Cryptography Part15 Cryptography Part1
5 Cryptography Part1
Alfred Ouyang
 
CRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYCRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITY
Kathirvel Ayyaswamy
 
A study on biometric authentication techniques
A study on biometric authentication techniquesA study on biometric authentication techniques
A study on biometric authentication techniques
Subhash Basistha
 
Cryptography
CryptographyCryptography
Cryptography
gueste4c97e
 
Public Key Cryptography and RSA algorithm
Public Key Cryptography and RSA algorithmPublic Key Cryptography and RSA algorithm
Public Key Cryptography and RSA algorithm
Indra97065
 
Gesture recognition
Gesture recognitionGesture recognition
Gesture recognition
PrachiWadekar
 
Firewall presentation
Firewall presentationFirewall presentation
Firewall presentationAmandeep Kaur
 
Biometric Security advantages and disadvantages
Biometric Security advantages and disadvantagesBiometric Security advantages and disadvantages
Biometric Security advantages and disadvantages
Prabh Jeet
 

Viewers also liked (20)

Cryptography
Cryptography Cryptography
Cryptography
 
Cipher techniques
Cipher techniquesCipher techniques
Cipher techniques
 
Cryptography
CryptographyCryptography
Cryptography
 
Cryptanalysis - basic ciphers and a bit more
Cryptanalysis - basic ciphers and a bit moreCryptanalysis - basic ciphers and a bit more
Cryptanalysis - basic ciphers and a bit more
 
Cryptography
CryptographyCryptography
Cryptography
 
Biometric technology
Biometric technologyBiometric technology
Biometric technology
 
Substitution Cipher
Substitution CipherSubstitution Cipher
Substitution Cipher
 
Multi modal biometric system
Multi modal biometric systemMulti modal biometric system
Multi modal biometric system
 
5. message authentication and hash function
5. message authentication and hash function5. message authentication and hash function
5. message authentication and hash function
 
Biometrics/fingerprint sensors
Biometrics/fingerprint sensorsBiometrics/fingerprint sensors
Biometrics/fingerprint sensors
 
5 Cryptography Part1
5 Cryptography Part15 Cryptography Part1
5 Cryptography Part1
 
CRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITYCRYPTOGRAPHY AND NETWORK SECURITY
CRYPTOGRAPHY AND NETWORK SECURITY
 
A study on biometric authentication techniques
A study on biometric authentication techniquesA study on biometric authentication techniques
A study on biometric authentication techniques
 
Cryptography
CryptographyCryptography
Cryptography
 
IP Security
IP SecurityIP Security
IP Security
 
biometrics
biometricsbiometrics
biometrics
 
Public Key Cryptography and RSA algorithm
Public Key Cryptography and RSA algorithmPublic Key Cryptography and RSA algorithm
Public Key Cryptography and RSA algorithm
 
Gesture recognition
Gesture recognitionGesture recognition
Gesture recognition
 
Firewall presentation
Firewall presentationFirewall presentation
Firewall presentation
 
Biometric Security advantages and disadvantages
Biometric Security advantages and disadvantagesBiometric Security advantages and disadvantages
Biometric Security advantages and disadvantages
 

Similar to overview of cryptographic techniques

Cipher techniques
Cipher techniquesCipher techniques
Cipher techniques
saqib1611
 
Cryptography Introduction
Cryptography IntroductionCryptography Introduction
Cryptography Introduction
indupps
 
Cns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption TechniquesCns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption Techniques
babak danyal
 
Classical Encryption Techniques in Network Security
Classical Encryption Techniques in Network SecurityClassical Encryption Techniques in Network Security
Classical Encryption Techniques in Network Security
babak danyal
 
UNIT 2.ppt
UNIT 2.pptUNIT 2.ppt
UNIT 2.ppt
Manoj R. Kharde
 
Cryptography and Network security # Lecture 4
Cryptography and Network security # Lecture 4Cryptography and Network security # Lecture 4
Cryptography and Network security # Lecture 4
Kabul Education University
 
EncryptionTechChap2.ppt
EncryptionTechChap2.pptEncryptionTechChap2.ppt
EncryptionTechChap2.ppt
rajirajesh8
 
Cryptography & network security
Cryptography & network securityCryptography & network security
Cryptography & network securitysathu30
 
ch02.ppt
ch02.pptch02.ppt
ch02.ppt
ssuser4198c4
 
Symmetric Encryption Techniques
Symmetric Encryption Techniques Symmetric Encryption Techniques
Symmetric Encryption Techniques
Dr. Kapil Gupta
 
Pertemuan 7 cryptography
Pertemuan 7  cryptographyPertemuan 7  cryptography
Pertemuan 7 cryptography
newbie2019
 
Cryptography & Network Security.ppt-1.pdf
Cryptography & Network Security.ppt-1.pdfCryptography & Network Security.ppt-1.pdf
Cryptography & Network Security.ppt-1.pdf
NirajKumar620142
 
Elementary cryptography
Elementary cryptographyElementary cryptography
Elementary cryptography
G Prachi
 
Cryptography and network security Nit701
Cryptography and network security Nit701Cryptography and network security Nit701
Cryptography and network security Nit701
Amit Pathak
 
Cryptography & Steganography
Cryptography & SteganographyCryptography & Steganography
Cryptography & Steganography
Animesh Shaw
 
Cryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptxCryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptx
RobertCarreonBula
 
cryptography.ppt
cryptography.pptcryptography.ppt
cryptography.ppt
AkshayaPriyaJanartha
 
DES-lecture (1).ppt
DES-lecture (1).pptDES-lecture (1).ppt
DES-lecture (1).ppt
MrsPrabhaBV
 

Similar to overview of cryptographic techniques (20)

Cipher techniques
Cipher techniquesCipher techniques
Cipher techniques
 
Cryptography Introduction
Cryptography IntroductionCryptography Introduction
Cryptography Introduction
 
Cns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption TechniquesCns 13f-lec03- Classical Encryption Techniques
Cns 13f-lec03- Classical Encryption Techniques
 
Classical Encryption Techniques in Network Security
Classical Encryption Techniques in Network SecurityClassical Encryption Techniques in Network Security
Classical Encryption Techniques in Network Security
 
UNIT 2.ppt
UNIT 2.pptUNIT 2.ppt
UNIT 2.ppt
 
Ch02
Ch02Ch02
Ch02
 
Cryptography and Network security # Lecture 4
Cryptography and Network security # Lecture 4Cryptography and Network security # Lecture 4
Cryptography and Network security # Lecture 4
 
EncryptionTechChap2.ppt
EncryptionTechChap2.pptEncryptionTechChap2.ppt
EncryptionTechChap2.ppt
 
Cryptography & network security
Cryptography & network securityCryptography & network security
Cryptography & network security
 
ch02.ppt
ch02.pptch02.ppt
ch02.ppt
 
Symmetric Encryption Techniques
Symmetric Encryption Techniques Symmetric Encryption Techniques
Symmetric Encryption Techniques
 
Pertemuan 7 cryptography
Pertemuan 7  cryptographyPertemuan 7  cryptography
Pertemuan 7 cryptography
 
Cryptography & Network Security.ppt-1.pdf
Cryptography & Network Security.ppt-1.pdfCryptography & Network Security.ppt-1.pdf
Cryptography & Network Security.ppt-1.pdf
 
Elementary cryptography
Elementary cryptographyElementary cryptography
Elementary cryptography
 
Cryptography and network security Nit701
Cryptography and network security Nit701Cryptography and network security Nit701
Cryptography and network security Nit701
 
Cryptography & Steganography
Cryptography & SteganographyCryptography & Steganography
Cryptography & Steganography
 
Ch03
Ch03Ch03
Ch03
 
Cryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptxCryptography and steganography lesson and discription.pptx
Cryptography and steganography lesson and discription.pptx
 
cryptography.ppt
cryptography.pptcryptography.ppt
cryptography.ppt
 
DES-lecture (1).ppt
DES-lecture (1).pptDES-lecture (1).ppt
DES-lecture (1).ppt
 

Recently uploaded

Democratizing Fuzzing at Scale by Abhishek Arya
Democratizing Fuzzing at Scale by Abhishek AryaDemocratizing Fuzzing at Scale by Abhishek Arya
Democratizing Fuzzing at Scale by Abhishek Arya
abh.arya
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
Jayaprasanna4
 
TECHNICAL TRAINING MANUAL GENERAL FAMILIARIZATION COURSE
TECHNICAL TRAINING MANUAL   GENERAL FAMILIARIZATION COURSETECHNICAL TRAINING MANUAL   GENERAL FAMILIARIZATION COURSE
TECHNICAL TRAINING MANUAL GENERAL FAMILIARIZATION COURSE
DuvanRamosGarzon1
 
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
AJAYKUMARPUND1
 
Quality defects in TMT Bars, Possible causes and Potential Solutions.
Quality defects in TMT Bars, Possible causes and Potential Solutions.Quality defects in TMT Bars, Possible causes and Potential Solutions.
Quality defects in TMT Bars, Possible causes and Potential Solutions.
PrashantGoswami42
 
Gen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdfGen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdf
gdsczhcet
 
addressing modes in computer architecture
addressing modes  in computer architectureaddressing modes  in computer architecture
addressing modes in computer architecture
ShahidSultan24
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
Kamal Acharya
 
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdfCOLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
Kamal Acharya
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Sreedhar Chowdam
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
Kamal Acharya
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
karthi keyan
 
MCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdfMCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdf
Osamah Alsalih
 
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
bakpo1
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
Neometrix_Engineering_Pvt_Ltd
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
R&R Consult
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
Jayaprasanna4
 
Vaccine management system project report documentation..pdf
Vaccine management system project report documentation..pdfVaccine management system project report documentation..pdf
Vaccine management system project report documentation..pdf
Kamal Acharya
 
The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
Pipe Restoration Solutions
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Teleport Manpower Consultant
 

Recently uploaded (20)

Democratizing Fuzzing at Scale by Abhishek Arya
Democratizing Fuzzing at Scale by Abhishek AryaDemocratizing Fuzzing at Scale by Abhishek Arya
Democratizing Fuzzing at Scale by Abhishek Arya
 
ethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.pptethical hacking in wireless-hacking1.ppt
ethical hacking in wireless-hacking1.ppt
 
TECHNICAL TRAINING MANUAL GENERAL FAMILIARIZATION COURSE
TECHNICAL TRAINING MANUAL   GENERAL FAMILIARIZATION COURSETECHNICAL TRAINING MANUAL   GENERAL FAMILIARIZATION COURSE
TECHNICAL TRAINING MANUAL GENERAL FAMILIARIZATION COURSE
 
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
Pile Foundation by Venkatesh Taduvai (Sub Geotechnical Engineering II)-conver...
 
Quality defects in TMT Bars, Possible causes and Potential Solutions.
Quality defects in TMT Bars, Possible causes and Potential Solutions.Quality defects in TMT Bars, Possible causes and Potential Solutions.
Quality defects in TMT Bars, Possible causes and Potential Solutions.
 
Gen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdfGen AI Study Jams _ For the GDSC Leads in India.pdf
Gen AI Study Jams _ For the GDSC Leads in India.pdf
 
addressing modes in computer architecture
addressing modes  in computer architectureaddressing modes  in computer architecture
addressing modes in computer architecture
 
Cosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdfCosmetic shop management system project report.pdf
Cosmetic shop management system project report.pdf
 
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdfCOLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
COLLEGE BUS MANAGEMENT SYSTEM PROJECT REPORT.pdf
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
 
Student information management system project report ii.pdf
Student information management system project report ii.pdfStudent information management system project report ii.pdf
Student information management system project report ii.pdf
 
CME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional ElectiveCME397 Surface Engineering- Professional Elective
CME397 Surface Engineering- Professional Elective
 
MCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdfMCQ Soil mechanics questions (Soil shear strength).pdf
MCQ Soil mechanics questions (Soil shear strength).pdf
 
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
一比一原版(SFU毕业证)西蒙菲莎大学毕业证成绩单如何办理
 
Standard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - NeometrixStandard Reomte Control Interface - Neometrix
Standard Reomte Control Interface - Neometrix
 
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxCFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptx
 
ethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.pptethical hacking-mobile hacking methods.ppt
ethical hacking-mobile hacking methods.ppt
 
Vaccine management system project report documentation..pdf
Vaccine management system project report documentation..pdfVaccine management system project report documentation..pdf
Vaccine management system project report documentation..pdf
 
The Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdfThe Benefits and Techniques of Trenchless Pipe Repair.pdf
The Benefits and Techniques of Trenchless Pipe Repair.pdf
 
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdfTop 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
Top 10 Oil and Gas Projects in Saudi Arabia 2024.pdf
 

overview of cryptographic techniques

  • 1. Overview of Cryptographic Techniques Hector M Lugo-Cordero CIS 4361 Secure Operating System Administration 1
  • 2. 2 Resources Used • Lecture slides from Dr Ratan Guha CNT 6519 Wireless Security Forensics • Cryptography and Network Security, Fourth Edition, by William Stallings • Lecture slides for the textbook by Lawrie Brown • Lecture slides by Henric Johnson,Blekinge Institute of Technology, Sweden
  • 3. 3 OOuuttlliinnee • Some Basic Terminology • Conventional Encryption Principles • Characteristics of Cryptographic Techniques • Symmetric Encryption • Classical Symmetric Encryption Algorithms • Modern Symmetric Encryption Techniques
  • 4. 4 Some Basic Terminology • plaintext - original message • ciphertext - coded message • cipher - algorithm for transforming plaintext to ciphertext • key - info used in cipher known only to sender/receiver • encipher (encrypt) - converting plaintext to ciphertext • decipher (decrypt) - recovering ciphertext from plaintext • cryptography - study of encryption principles/methods • cryptanalysis (codebreaking) - study of principles/ methods of deciphering ciphertext without knowing key • cryptology - field of both cryptography and cryptanalysis
  • 5. 5 CCoonnvveennttiioonnaall EEnnccrryyppttiioonn PPrriinncciipplleess • An encryption scheme has five ingredients: – Plaintext – Encryption algorithm – Secret Key – Ciphertext – Decryption algorithm • Security depends on the secrecy of the key, not the secrecy of the algorithm
  • 6. 6 Characteristics ooff CCrryyppttooggrraapphhiicc TTeecchhnniiqquueess • Classified along three independent dimensions: – The type of operations used for transforming plaintext to ciphertext – The number of keys used • symmetric (single key) • asymmetric (two-keys, or public-key encryption) – The way in which the plaintext is processed
  • 7. 7 Symmetric Encryption • or conventional / private-key / single-key • sender and recipient share a common key • all classical encryption algorithms are private-key • was only type prior to invention of public-key in 1970’s • and by far most widely used
  • 9. 9 Requirements • two requirements for secure use of symmetric encryption: – a strong encryption algorithm – a secret key known only to sender / receiver • mathematically have: Y = EK(X) [= E(K, X) ] X = DK(Y) [= D(K, Y) ] • assume encryption algorithm is known • implies a secure channel to distribute key
  • 10. 10 Brute Force Search • always possible to simply try every key • most basic attack, proportional to key size • assume either know / recognize plaintext Key Size (bits) Number of Alternative Keys Time required at 1 decryption/μs Time required at 106 decryptions/μs 32 232 = 4.3 ´ 109 231 μs = 35.8 minutes 2.15 milliseconds 56 256 = 7.2 ´ 1016 255 μs = 1142 years 10.01 hours 128 2128 = 3.4 ´ 1038 2127 μs = 5.4 ´ 1024 years 5.4 ´ 1018 years 168 2168 = 3.7 ´ 1050 2167 μs = 5.9 ´ 1036 years 5.9 ´ 1030 years 26 characters (permutation) 26! = 4 ´ 1026 2 ´ 1026 μs = 6.4 ´ 1012 years 6.4 ´ 106 years
  • 11. 11 Classical Substitution Ciphers • where letters of plaintext are replaced by other letters or by numbers or symbols • or if plaintext is viewed as a sequence of bits, then substitution involves replacing plaintext bit patterns with ciphertext bit patterns
  • 12. 12 Caesar Cipher • earliest known substitution cipher • by Julius Caesar • first attested use in military affairs • replaces each letter by 3rd letter after • example: meet me after the toga party PHHW PH DIWHU WKH WRJD SDUWB
  • 13. 13 Caesar Cipher • can define transformation as: 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 D E F G H I J K L M N O P Q R S T U V W X Y Z A B C • mathematically give each letter a number 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 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 • then have Caesar cipher as: c = E(p) = (p + k) mod (26) p = D(c) = (c – k) mod (26)
  • 14. 14 Monoalphabetic Cipher • rather than just shifting the alphabet • could shuffle (jumble) the letters arbitrarily • each plaintext letter maps to a different random ciphertext letter • hence key is 26 letters long Plain: abcdefghijklmnopqrstuvwxyz Cipher: DKVQFIBJWPESCXHTMYAUOLRGZN Plaintext: ifwewishtoreplaceletters Ciphertext: WIRFRWAJUHYFTSDVFSFUUFYA
  • 15. 15 Playfair Cipher • not even the large number of keys in a monoalphabetic cipher provides security • one approach to improving security was to encrypt multiple letters • the Playfair Cipher is an example • invented by Charles Wheatstone in 1854, but named after his friend Baron Playfair
  • 16. 16 Playfair Key Matrix • a 5X5 matrix of letters based on a keyword • fill in letters of keyword (minus duplicates) • fill rest of matrix with other letters • eg. using the keyword MONARCHY M O N A R C H Y B D E F G I/J K L P Q S T U V W X Z
  • 17. 17 Encrypting and Decrypting • plaintext is encrypted two letters at a time 1. if a pair is a repeated letter, insert filler like 'X’ (low probability of appearance in language) 2. if both letters fall in the same row, replace each with letter to right (wrapping back to start from end) 3. if both letters fall in the same column, replace each with the letter below it (again wrapping to top from bottom) 4. otherwise each letter is replaced by the letter in the same row and in the column of the other letter of the pair Wireless Wi re le sx sz XG MK UL XA XT
  • 18. 18 Polyalphabetic Ciphers • polyalphabetic substitution ciphers • A set of related monoalphabetic substitution rules is used • use a key to select which alphabet is used for each letter of the message • use each alphabet in turn • repeat from start after end of key is reached • make cryptanalysis harder with more alphabets to guess and flatter frequency distribution Key: deceptive 3 4 2 4 15 19 8 21 4 plaintext: wireless 22 8 17 4 11 4 18 18 ciphertext: zmtiaxao 25 12 19 8 26 23 26 39
  • 19. 19 Vigenère Cipher • simplest polyalphabetic substitution cipher • effectively multiple caesar ciphers • key is multiple letters long K = k1 k2 ... kd • ith letter specifies ith alphabet to use • use each alphabet in turn • repeat from start after d letters in message • decryption simply works in reverse
  • 20. 20 Example of Vigenère Cipher • write the plaintext out • write the keyword repeated above it • use each key letter as a caesar cipher key • encrypt the corresponding plaintext letter • eg using keyword deceptive key: deceptivedeceptivedeceptive plaintext: wearediscoveredsaveyourself ciphertext:ZICVTWQNGRZGVTWAVZHCQYGLMGJ
  • 21. Vernam Cipher and One-time Pad • Keyword is as long as the plaintext and has no statistical relationship to it. • Vernam system works on binary data with ith bit of text exclusive ored with ith bit of key to produce ith bit of cipher • In one one-time pad key is used only once • This scheme is unbreakable 21
  • 22. Transposition Cipher • Mapping is performed by some sort of permutation on the plaintext letters. • Example: Rail fence of depth 2 text : meet me after the toga party m e m a t r h t g p r y e t e f e t e o a a t cipher: MEMATRHTGPRYETEFETEOAAT Rail fence of depth 2 22
  • 23. Classical Ciphers • Caesar Cipher • Monoalphabetic Cipher • Playfair Cipher • Polyphabetic Cipher • Vigenère Cipher • Vernam Cipher and One-time Pad • Transposition Cipher Cryptography -Part -I 23
  • 24. Modern Block Ciphers • now look at modern block ciphers • one of the most widely used types of cryptographic algorithms • provide secrecy /authentication services • focus on DES (Data Encryption Standard) • to illustrate block cipher design principles
  • 25. Block vs Stream Ciphers • block ciphers process messages in blocks, each of which is then en/decrypted • like a substitution on very big characters – 64-bits or more • stream ciphers process messages a bit or byte at a time when en/decrypting • many current ciphers are block ciphers • broader range of applications
  • 26. Block Cipher Principles • most symmetric block ciphers are based on a Feistel Cipher Structure • needed since must be able to decrypt ciphertext to recover messages efficiently • block ciphers look like an extremely large substitution • would need table of 264 entries for a 64-bit block • instead create from smaller building blocks • using idea of a product cipher
  • 28. Claude Shannon and Substitution- Permutation Ciphers • Claude Shannon introduced idea of substitution-permutation (S-P) networks in 1949 paper • form basis of modern block ciphers • S-P nets are based on the two primitive cryptographic operations seen before: – substitution (S-box) – permutation (P-box) • provide confusion & diffusion of message & key
  • 29. Confusion and Diffusion • cipher needs to completely obscure statistical properties of original message • a one-time pad does this • more practically Shannon suggested combining S & P elements to obtain: • diffusion – dissipates statistical structure of plaintext over bulk of ciphertext • confusion – makes relationship between ciphertext and key as complex as possible
  • 30. Feistel Cipher Structure • Horst Feistel devised the feistel cipher – based on concept of invertible product cipher • partitions input block into two halves – process through multiple rounds which – perform a substitution on left data half – based on round function of right half & subkey – then have permutation swapping halves • implements Shannon’s S-P net concept
  • 32. Feistel Cipher Design Elements • block size • key size • number of rounds • subkey generation algorithm • round function • fast software en/decryption • ease of analysis

Editor's Notes

  1. Briefly review some terminology used throughout the course.
  2. Symmetric encryption, also referred to as conventional encryption or single-key encryption, was the only type of encryption in use prior to the development of public-key encryption in the 1970s. It remains by far the most widely used of the two types of encryption. All traditional schemes are symmetric / single key / private-key encryption algorithms, with a single key, used for both encryption and decryption. Since both sender and receiver are equivalent, either can encrypt or decrypt messages using that common key.
  3. Detail the five ingredients of the symmetric cipher model, shown in Stallings Figure 2.1: plaintext - original message encryption algorithm – performs substitutions/transformations on plaintext secret key – control exact substitutions/transformations used in encryption algorithm ciphertext - scrambled message decryption algorithm – inverse of encryption algorithm
  4. We assume that it is impractical to decrypt a message on the basis of the cipher- text plus knowledge of the encryption/decryption algorithm, and do not need to keep the algorithm secret; rather we only need to keep the key secret. This feature of symmetric encryption is what makes it feasible for widespread use. It allows easy distribution of s/w and h/w implementations. Can take a closer look at the essential elements of a symmetric encryption scheme: mathematically it can be considered a pair of functions with: plaintext X, ciphertext Y, key K, encryption algorithm EK, decryption algorithm DK.
  5. A brute-force attack involves trying every possible key until an intelligible translation of the ciphertext into plaintext is obtained. On average, half of all possible keys must be tried to achieve success. Stallings Table 2.2 shows how much time is required to conduct a brute-force attack, for various common key sizes (DES is 56, AES is 128, Triple-DES is 168, plus general mono-alphabetic cipher), where either a single system or a million parallel systems, are used.
  6. In this section and the next, we examine a sampling of what might be called classical encryption techniques. A study of these techniques enables us to illustrate the basic approaches to symmetric encryption used today and the types of cryptanalytic attacks that must be anticipated. The two basic building blocks of all encryption technique are substitution and transposition. We examine these in the next two sections. Finally, we discuss a system that combine both substitution and transposition.
  7. Substitution ciphers form the first of the fundamental building blocks. The core idea is to replace one basic unit (letter/byte) with another. Whilst the early Greeks described several substitution ciphers, the first attested use in military affairs of one was by Julius Caesar, described by him in Gallic Wars (cf. Kahn pp83-84). Still call any cipher using a simple letter shift a caesar cipher, not just those with shift 3.
  8. This mathematical description uses modulo (clock) arithmetic. Here, when you reach Z you go back to A and start again. Mod 26 implies that when you reach 26, you use 0 instead (ie the letter after Z, or 25 + 1 goes to A or 0). Example: howdy (7,14,22,3,24) encrypted using key f (ie a shift of 5) is MTBID
  9. With only 25 possible keys, the Caesar cipher is far from secure. A dramatic increase in the key space can be achieved by allowing an arbitrary substitution, where the translation alphabet can be any permutation of the 26 alphabetic characters. See example translation alphabet, and an encrypted message using it.
  10. Consider ways to reduce the "spikyness" of natural language text, since if just map one letter always to another, the frequency distribution is just shuffled. One approach is to encrypt more than one letter at once. The Playfair cipher is an example of doing this.
  11. The best-known multiple-letter encryption cipher is the Playfair, which treats digrams in the plaintext as single units and translates these units into ciphertext digrams. The Playfair algorithm is based on the use of a 5x5 matrix of letters constructed using a keyword. The rules for filling in this 5x5 matrix are: L to R, top to bottom, first with keyword after duplicate letters have been removed, and then with the remain letters, with I/J used as a single letter. This example comes from Dorothy Sayer's book "Have His Carcase", in which Lord Peter Wimsey solves it, and describes the use of a probably word attack.
  12. Plaintext is encrypted two letters at a time,according to the rules as shown. Note how you wrap from right side back to left, or from bottom back to top. if a pair is a repeated letter, insert a filler like 'X', eg. "balloon" encrypts as "ba lx lo on" if both letters fall in the same row, replace each with letter to right (wrapping back to start from end), eg. “ar" encrypts as "RM" if both letters fall in the same column, replace each with the letter below it (again wrapping to top from bottom), eg. “mu" encrypts to "CM" otherwise each letter is replaced by the one in its row in the column of the other letter of the pair, eg. “hs" encrypts to "BP", and “ea" to "IM" or "JM" (as desired) Decrypting of course works exactly in reverse. Can see this by working the example pairs shown, backwards.
  13. One approach to reducing the "spikyness" of natural language text is used the Playfair cipher which encrypts more than one letter at once. We now consider the other alternative, using multiple cipher alphabets in turn. This gives the attacker more work, since many alphabets need to be guessed, and because the frequency distribution is more complex, since the same plaintext letter could be replaced by several ciphertext letters, depending on which alphabet is used. The general name for this approach is a polyalphabetic substitution cipher. All these techniques have the following features in common: A set of related monoalphabetic substitution rules is used. 2. A key determines which particular rule is chosen for a given transformation.
  14. The best known, and one of the simplest, such algorithms is referred to as the Vigenère cipher, where the set of related monoalphabetic substitution rules consists of the 26 Caesar ciphers, with shifts of 0 through 25. Each cipher is denoted by a key letter, which is the ciphertext letter that substitutes for the plaintext letter ‘a’, and which are each used in turn, as shown next.
  15. Discuss this simple example from text Stallings section 2.2.
  16. Modern block ciphers are widely used to provide encryption of quantities of information, and/or a cryptographic checksum to ensure the contents have not been altered. We continue to use block ciphers because they are comparatively fast, and because we know a fair amount about how to design them. Will use the widely known DES algorithm to illustrate some key block cipher design principles.
  17. Block ciphers work a on block / word at a time, which is some number of bits. All of these bits have to be available before the block can be processed. Stream ciphers work on a bit or byte of the message at a time, hence process it as a “stream”. Block ciphers are currently better analysed, and seem to have a broader range of applications, hence focus on them.
  18. Most symmetric block encryption algorithms in current use are based on a structure referred to as a Feistel block cipher. A block cipher operates on a plaintext block of n bits to produce a ciphertext block of n bits. An arbitrary reversible substitution cipher for a large block size is not practical, however, from an implementation and performance point of view. In general, for an n-bit general substitution block cipher, the size of the key is n x 2n. For a 64-bit block, which is a desirable length to thwart statistical attacks, the key size is 64 x 264 = 270 = 1021 bits. In considering these difficulties, Feistel points out that what is needed is an approximation to the ideal block cipher system for large n, built up out of components that are easily realizable.
  19. Feistel refers to an n-bit general substitution as an ideal block cipher, because it allows for the maximum number of possible encryption mappings from the plaintext to ciphertext block. A 4-bit input produces one of 16 possible input states, which is mapped by the substitution cipher into a unique one of 16 possible output states, each of which is represented by 4 ciphertext bits. The encryption and decryption mappings can be defined by a tabulation, as shown in Stallings Figure 3.1. It illustrates a tiny 4-bit substitution to show that each possible input can be arbitrarily mapped to any output - which is why its complexity grows so rapidly.
  20. Claude Shannon’s 1949 paper has the key ideas that led to the development of modern block ciphers. Critically, it was the technique of layering groups of S-boxes separated by a larger P-box to form the S-P network, a complex form of a product cipher. He also introduced the ideas of confusion and diffusion, notionally provided by S-boxes and P-boxes (in conjunction with S-boxes).
  21. The terms diffusion and confusion were introduced by Claude Shannon to capture the two basic building blocks for any cryptographic system. Every block cipher involves a transformation of a block of plaintext into a block of ciphertext, where the transformation depends on the key. The mechanism of diffusion seeks to make the statistical relationship between the plaintext and ciphertext as complex as possible in order to thwart attempts to deduce the key. Confusion seeks to make the relationship between the statistics of the ciphertext and the value of the encryption key as complex as possible, again to thwart attempts to discover the key. So successful are diffusion and confusion in capturing the essence of the desired attributes of a block cipher that they have become the cornerstone of modern block cipher design.
  22. Horst Feistel, working at IBM Thomas J Watson Research Labs devised a suitable invertible cipher structure in early 70's. One of Feistel's main contributions was the invention of a suitable structure which adapted Shannon's S-P network in an easily inverted structure. It partitions input block into two halves which are processed through multiple rounds which perform a substitution on left data half, based on round function of right half & subkey, and then have permutation swapping halves. Essentially the same h/w or s/w is used for both encryption and decryption, with just a slight change in how the keys are used. One layer of S-boxes and the following P-box are used to form the round function.
  23. Stallings Figure 3.2 illustrates the classical feistel cipher structure, with data split in 2 halves, processed through a number of rounds which perform a substitution on left half using output of round function on right half & key, and a permutation which swaps halves, as listed previously.
  24. The exact realization of a Feistel network depends on the choice of the following parameters and design features: block size - increasing size improves security, but slows cipher key size - increasing size improves security, makes exhaustive key searching harder, but may slow cipher number of rounds - increasing number improves security, but slows cipher subkey generation algorithm - greater complexity can make analysis harder, but slows cipher round function - greater complexity can make analysis harder, but slows cipher fast software en/decryption - more recent concern for practical use ease of analysis - for easier validation & testing of strength
  25. The process of decryption with a Feistel cipher, as shown in Stallings Figure 3.3, is essentially the same as the encryption process. The rule is as follows: Use the ciphertext as input to the algorithm, but use the subkeys Ki in reverse order. That is, use Kn in the first round, Kn–1 in the second round, and so on until K1 is used in the last round. This is a nice feature because it means we need not implement two different algorithms, one for encryption and one for decryption.