390 Hills System
-
Upload
karthick-narayanan -
Category
Documents
-
view
24 -
download
0
description
Transcript of 390 Hills System
![Page 1: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/1.jpg)
390 Codes, Ciphers, and Cryptography
Polygraphic Substitution Ciphers – Hill’s System
![Page 2: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/2.jpg)
2
Hill’s System
We now look at the system for enciphering blocks of text developed by Lester Hill.
Matrices form the basis of this substitution cipher!
We’ll work with blocks of size two letters – the idea can be generalized to larger blocks.
![Page 3: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/3.jpg)
3
Steps to Encipher a Message
1. Choose a 2 x 2 matrix
with entries in Z26 for a key. Make sure that (ad – bc)-1 (mod 26) exists, i.e.
(ad – bc) = 1, 3, 5, 7, 9, 11, 15, 17, 19, 21, 23, or 25.
This will guarantee that A-1 exists (mod 26).
![Page 4: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/4.jpg)
4
Steps to Encipher a Message
2. Split the plaintext into pairs and assign numbers to each plaintext letter, with a = 1, b = 2, … , z = 26 = 0 (mod 26).
Plaintext: p1p2|p3p4| … |pn-1pn
If necessary, append an extra character to the plaintext to get an even number of plaintext characters.
![Page 5: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/5.jpg)
5
Steps to Encipher a Message
![Page 6: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/6.jpg)
6
Example 8
Use Hill’s scheme to encipher the message: “Meet me at the usual place at ten rather than eight o’clock.”
![Page 7: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/7.jpg)
7
Example 8
Solution: For the key, choose a 2 x 2 matrix, with entries in Z26.
Note that
(ad – bc) (mod 26)
= (9*7 – 4*5) (mod 26)
= (63 – 20) (mod 26)
= 43 (mod 26)
= 17 (mod 26)
and 17-1 (mod 26) exists! More on this later …
![Page 8: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/8.jpg)
8
Example 8
Next convert the plaintext into pairs of numbers from Z26:
me | et | me | at … cl | oc | kz. 13,5 | 5,20 | 13,5 | 1,20 | … 3,12 | 15,3 | 11,0 Now convert the plaintext to numbers to
ciphertext numbers, using (*) above.
![Page 9: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/9.jpg)
9
Example 8
![Page 10: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/10.jpg)
10
Example 8
Thus, “me” is encrypted as “GV”. Try the next pair!
![Page 11: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/11.jpg)
11
Example 8
![Page 12: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/12.jpg)
12
Example 8
Thus, “et” is encrypted as “UI”. HW – Finish encrypting message! Note that for the word “meet”, the first “e”
is encrypted as “G” and the second “e” is encrypted as “U”.
Frequency analysis won’t work for this scheme!
![Page 13: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/13.jpg)
13
Deciphering a Message
To decipher a message encrypted with Hill’s Scheme, we can use the idea of matrix inverses!
Since ciphertext (ck,ck+1) is obtained from plaintext (pk,pk+1) by multiplying key matrix A by plaintext (pk,pk+1), all we need to do is multiply matrix A-1 by ciphertext (ck,ck+1).
![Page 14: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/14.jpg)
14
Deciphering a Message
![Page 15: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/15.jpg)
15
Deciphering a Message
![Page 16: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/16.jpg)
16
Deciphering a Message
The same idea will work for matrices of numbers from Z26!
Matrix A will be invertible, provided that (ad-bc)-1 (mod 26) exists!
The only difference is that instead of 1/(ad-bc), we need to use (ad-bc)-1.
![Page 17: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/17.jpg)
17
Deciphering a Message
![Page 18: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/18.jpg)
18
Deciphering a Message
![Page 19: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/19.jpg)
19
Deciphering a Message
![Page 20: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/20.jpg)
20
Example 9
Decipher the ciphertext found above in Example 8!
Write ciphertext as pairs of numbers in Z26: GV | UI 7,22 | 21,9 Use the inverse of the key matrix to
decipher!
![Page 21: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/21.jpg)
21
Example 9
![Page 22: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/22.jpg)
22
Example 9
Thus, “GV” is deciphered as “me”. Repeat with “UI”.
![Page 23: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/23.jpg)
23
Example 9
![Page 24: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/24.jpg)
24
Example 9
Thus, “UI” is deciphered as “et”.
![Page 25: 390 Hills System](https://reader035.fdocuments.in/reader035/viewer/2022062313/55cf9959550346d0339ceca8/html5/thumbnails/25.jpg)
25
References
Cryptological Mathematics by Robert Edward Lewand (section on matrices).