06.01.2015 Views

Cryptology - Unofficial St. Mary's College of California Web Site

Cryptology - Unofficial St. Mary's College of California Web Site

Cryptology - Unofficial St. Mary's College of California Web Site

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

3.4. DECIPHERING DECIMATION CIPHERS 43<br />

To decipher a decimation cipher with key K we will need to find the inverse<br />

<strong>of</strong> K modulo 26 (the number that satisfies (K × )%26 = 1). It turns out<br />

that the inverse <strong>of</strong> 5 when working modulo 26 is 21: (5 × 21)%26 = 1. Since<br />

multiplying by 1 changes nothing, following a multiplication by 5 with another<br />

by 21 brings us back to our original message.<br />

The same is true for several other pairs <strong>of</strong> numbers. (The numbers that have<br />

multiplicative inverses are “proper” in the sense <strong>of</strong> the definition <strong>of</strong> Decimation<br />

ciphers on page 40.) We will learn how to produce these pairs in Chapter 4.<br />

For now, we simply list them.<br />

enciphering key 1 3 5 7 9 11 15 17 19 21 23 25<br />

deciphering key 1 9 21 15 3 19 7 23 11 5 17 25<br />

Figure 3.2: Enciphering/Deciphering pairs modulo 26.<br />

Notice that the deciphering key is seldom the same as the enciphering key. Do<br />

not make the mistake <strong>of</strong> simply reusing the enciphering key, or using its negative.<br />

A Decimation Cipher will only decipher properly when the correct key is used.<br />

Examples:<br />

(1) Decipher EJWAV DEOY, whose enciphering key was k = 5<br />

From Figure 3.2 the multiplicative inverse <strong>of</strong> 5 is 21. So if we multiply the<br />

ciphernumbers by 21 and then find their remainders mod 26 we should<br />

have our message back. Let’s see.<br />

ciphertext E J W A V D E O Y<br />

ciphernumbers 5 10 23 1 22 4 5 15 25<br />

×21 105 210 483 21 462 84 21 63 105<br />

%26 1 2 15 21 20 6 1 3 5<br />

plaintext a b o u t f a c e<br />

Multiplying by 21 really did undo the multiplication by 5 and so did<br />

decipher our message.<br />

(2) Decipher MKCCKFI, if the enciphering number was 7.<br />

The key was multiply by 7. However, if we try to divide by 7 to decipher<br />

we have troubles:<br />

ciphertext M K C C K F I<br />

ciphernumbers 13 11 3 3 11 6 9<br />

divide by 7 1.857 1.571 .429 .429 1.571 .857 1.286<br />

plaintext

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!