







Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!








Substitution Ciphers (1)
Monalphabetic substitution ciphers
Simplifications (1)
Coding characters into numbers
Caesar Cipher: Example
I C A M E I S A W I C O N Q U E R E D
8 2 0 12 4 8 18 0 22 8 2 14 13 16 20 4 17 4 3
11 5 3 15 7 11 21 3 25 11 5 17 16 19 23 7 20 7 6
L F D P H L V D Z L F R Q T X H U H G
0
2
4
6
8
10
12
14
7.
1.
3.
4.
12.
3
2
3.
7.
0.
0.
3.
2.
7. 7.
2.
0.
8.
6
9.
3
1.5 1.
0.
2.
0.
2
4
6
8
10
12
14
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
2
4
6
8
10
12
14
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
Character frequency
in a long English
plaintext
Character frequency
in the corresponding
ciphertext
for a shift cipher
2
4
6
8
10
12
14
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
Character frequency
in a long English
plaintext
Character frequency
in the corresponding
ciphertext
for a general
monoalphabetic
substitution cipher
2
4
6
8
10
12
14
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
2
4
6
8
10
12
14
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
2
4
6
8
10
12
14
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
2
4
6
8
10
12
14
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
2
4
6
8
10
12
14
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
R - 8
D - 7
E, H, K - 5
Polyalphabetic substitution ciphers
Simplifications (1)
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 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 a c 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 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 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 d f g h i j k l m n o p q r s t u v w x y z a b c d e g h i j k l m n o p q r s t u v w x y z a b c d e f h i j k l m n o p q r s t u v w x y z a b c d e f g i j k l m n o p q r s t u v w x y z a b c d e f g h j k l m n o p q r s t u v w x y z a b c d e f g h i k l m n o p q r s t u v w x y z a b c d e f g h i j l m n o p q r s t u v w x y z a b c d e f g h i j k m n o p q r s t u v w x y z a b c d e f g h i j k l n o p q r s t u v w x y z a b c d e f g h i j k l m o p q r s t u v w x y z a b c d e f g h i j k l m n p q r s t u v w x y z a b c d e f g h i j k l m n o q r s t u v w x y z a b c d e f g h i j k l m n o p r s t u v w x y z a b c d e f g h i j k l m n o p q s t u v w x y z a b c d e f g h i j k l m n o p q r t u v w x y z a b c d e f g h i j k l m n o p q r s u v w x y z a b c d e f g h i j k l m n o p q r s t v w x y z a b c d e f g h i j k l m n o p q r s t u w x y z a b c d e f g h i j k l m n o p q r s t u v x y z a b c d e f g h i j k l m n o p q r s t u v w y z a b c d e f g h i j k l m n o p q r s t u v w x z 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
plaintext: 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
1
2
3
Key = “nsa”
E O R
N O T
T O B
E
G G B
R G R
A G T
G G B
R
= 1 ∑
=
z
i a
i
p
26
1
26
1
..
2
2
=^ −
= −
∑ ∑
M R pi pi
2
4
6
8
10
12
14
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
Character frequency
in a long English
plaintext
Character frequency
in the corresponding
ciphertext
for a running-key
cipher
1 26
⋅ 100% ≈ 3.8 %
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
Substitution Ciphers (4)
Playfair Cipher
P L A Y F
I R S D G
M C H E B
K N O Q T
V W X Y Z
ciphertext block = message block · key matrix
key matrix · inverse key matrix = identity matrix
message block = ciphertext block · inverse key matrix
2
4
6
8
10
12
14
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
Character frequency
in a long English
plaintext
Character frequency
in the corresponding
ciphertext
for a transposition cipher
2
4
6
8
10
12
14
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
Transposition cipher
Example