KEMBAR78
Week 3 - Lecture 2 | PDF | Cipher | Cryptography
0% found this document useful (0 votes)
76 views14 pages

Week 3 - Lecture 2

Classical encryption techniques discussed include: 1. Substitution ciphers like the Caesar cipher and polyalphabetic ciphers like the Vigenere cipher. 2. The Vernam cipher/one-time pad introduced in 1918 which operates on binary data using a random key as long as the plaintext. 3. Transposition ciphers like the rail fence cipher and block/columnar transposition ciphers which rearrange the letter order of the plaintext.

Uploaded by

Hasan Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
76 views14 pages

Week 3 - Lecture 2

Classical encryption techniques discussed include: 1. Substitution ciphers like the Caesar cipher and polyalphabetic ciphers like the Vigenere cipher. 2. The Vernam cipher/one-time pad introduced in 1918 which operates on binary data using a random key as long as the plaintext. 3. Transposition ciphers like the rail fence cipher and block/columnar transposition ciphers which rearrange the letter order of the plaintext.

Uploaded by

Hasan Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

CS-381 Network Security

Week 3 – Lecture 2
Block Ciphers

Dr. Razi Arshad


Classical Encryption
Techniques
 Substitution Ciphers
 Monoalphabetic Ciphers
• Caesar Cipher
 Polyalphabetic Ciphers
• Vigenere Cipher
• Playfair Cipher
• Hill Cipher
• One-Time Pad
Vernam Cipher/
One-Time Pad
 Motivation: Selection of keyword that is as long as the
plaintext and has no statistical relationship to it

 Introduced by an AT&T engineer named Gilbert Vernam


in 1918

 The system works on binary data rather than letters

 The system can be expressed as follows:


 Encryption:
 Decryption:
 Where Ci, Pi, Ki is the ith binary digit of C iphertext,
Plaintext and Key.
Vernam Cipher/
One-Time Pad
 Use a random key (pad) which is as long as the
message, with no repetitions
 Key used for once and then is discarded, each new
message requires a new key of the same length as the
new message
 With such key, plaintext and ciphertext are
statistically independent
 Unconditionally secure (Unbreakable)
One-Time Pad
 Weaknesses: One time pad offers complete security
(unbreakable), but in practice has two fundamental
difficulties:
 Random key generation
 A heavily used system might require millions of
random characters on a regular basis
 Key Distribution & Protection
 For every message to be sent, a key of equal length
is needed by both sender and receiver
Relative Frequency of
Occurrence of Letters
Classical Encryption
Techniques
 Transposition (Permutation) Ciphers
 Rail Fence Technique
 Block (Columnar) Transposition
Technique
Transposition (Permutation)
Techniques
 Rearranging the letter order to hide the actual message
without altering the actual letters used
 Example: Rail Fence Cipher (ZigZag Cipher)
 Write message letters on alternate rows, and read off
cipher row by row
 The key for the rail fence cipher is the number of rails.
 Plaintext: MEET ME AFTER THE TOGA PARTY
 Ciphertext: MEMATRHTGPRYETEFETEOAAT

M . E . M . A . T . R . H . T . G . P . R . Y

. E . T . E . F . E . T . E . O . A . A . T .
Transposition (Permutation)
Techniques
 Decryption
 Number of columns = length of ciphertext
 Number of rows = key.
 Write ciphertext letters on alternate columns,
filling the rows forming rails
 Read off as rails

Ciphertext: ECLETXELN
E . C . L . E . T
. X . E . L . N .

Plaintext: EXCELLENT
Block (Columnar)
Transposition Ciphers
 Write message in rectangle-row by row, and read it off
column by column; but permute the order of the
columns.
 The order of columns becomes the key
 Example:
• Plaintext : ATTACK POSTPONED UNTIL TWO AM XYZ
• Ciphertext: TTNA APTM TSUO AODW COIX KNLY PETZ

Key 4 3 1 2 5 6 7
Plaintext A T T A C K P
O S T P O N E
D U N T I L T
W O A M X Y Z
Block Transposition:
Example 01
 Keyword: ZEBRAS
 Length of Word= 6 (Alphabets in a row)
 Alphabetical Order defines permutation. In this case “6 3 2 4 1 5”
 Plaintext: “WE ARE DISCOVERED FLEE AT ONCE”
Key 6 3 2 4 1 5
Plaintext W E A R E D
I S C O V E
R E D F L E
E A T O N C
E x x x x x

 Ciphertext: EVLNx ACDTx ESEAx ROFOx DEECx WIREE


Block Transposition:
Example 02
 Keyword: CORNELL
 Length of Word= 7 (Alphabets in a row)
 Alphabetical Order defines permutation. In this case
“1 6 7 5 2 3 4”
 Plaintext: “THE QUICK Key C O R N E L L
1 6 7 5 2 3 4
BROWN FOX JUMPED Plaintex T H E Q U I C
OVER THE LAZY DOG” t K B R O W N F
 Ciphertext: TKODEG O X J U M P E

UWMRYx INPTDx CFEHOx D O V E R T H


E L A Z Y D O
QOUEZx HBXOLx ERJVAx G x x x x x x
CrypTool
https://www.cryptool.org/en/
Overview- Classical
Encryption Techniques

You might also like