30.11.2012 Views

Code and ciphers: Julius Caesar, the Enigma and the internet

Code and ciphers: Julius Caesar, the Enigma and the internet

Code and ciphers: Julius Caesar, the Enigma and the internet

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

value can be expected to occur two or three times in a well-chosen cage. A<br />

cage such as (9, 9, 9, 0, 0, 0) is obviously very poor since <strong>the</strong> only key values<br />

that can be generated are 0, 1 (which occurs as 27), 9 <strong>and</strong> 18 <strong>and</strong> even <strong>the</strong>se<br />

are non-uniformly represented, viz:<br />

Key value 0 1 19 18<br />

Number of occurrences out of 64 possible 8 8 24 24<br />

Solving a message sent with such a cage wouldn’t be very difficult since<br />

<strong>the</strong>re are only four possible key values at any stage <strong>and</strong> two of <strong>the</strong>se are<br />

much more likely than <strong>the</strong> o<strong>the</strong>r two. In <strong>the</strong> case of such a poor cage as this<br />

<strong>the</strong> process of solution is easily illustrated.<br />

Example 10.3<br />

The following is <strong>the</strong> cipher text of a message which has been enciphered<br />

on a Hagelin with cage (0, 0, 0, 9, 9, 9). X is used for spacing/punctuation.<br />

Decrypt <strong>the</strong> message.<br />

ZCTAL BRDSV IBGDZ SMFVM.<br />

Solution<br />

With such a cage <strong>the</strong> only possible key values are 0, 1, 9 <strong>and</strong> 18. If we subtract<br />

each letter of <strong>the</strong> cipher from <strong>the</strong>se four values <strong>and</strong> write <strong>the</strong> resultant<br />

texts in four rows <strong>the</strong> decrypt must lie somewhere within <strong>the</strong> four<br />

rows. Since 9 <strong>and</strong> 18 are three times more likely to occur than 0 or 1 we<br />

would expect <strong>the</strong> majority of <strong>the</strong> plaintext letters to lie in <strong>the</strong> third <strong>and</strong><br />

fourth rows. X is used for spacing/punctuation <strong>and</strong>, to make it more<br />

obvious, we replace it by ^ wherever it occurs.<br />

We can save ourselves <strong>the</strong> tedium of subtracting <strong>the</strong> numerical equivalent<br />

of <strong>the</strong> cipher letters from <strong>the</strong> key values if we construct a table once<br />

<strong>and</strong> for all. This has <strong>the</strong> additional advantage that, unlike <strong>the</strong> book cipher<br />

tables of Chapter 7, <strong>the</strong> same table can be used for both encipherment <strong>and</strong><br />

decipherment, because of <strong>the</strong> symmetry of <strong>the</strong> Hagelin encipherment/decipherment<br />

process mentioned above. When we have <strong>the</strong> table,<br />

given by Table 10.2, we simply look up <strong>the</strong> entries in <strong>the</strong> row corresponding<br />

to <strong>the</strong> cipher, or plaintext, letter <strong>and</strong> <strong>the</strong> column of <strong>the</strong> key value to<br />

obtain <strong>the</strong> plaintext, or cipher, letter, giving Table 10.3. The space marks<br />

are helpful <strong>and</strong> it is easy to pick out <strong>the</strong> plaintext, marked in bold in Table<br />

10.3:<br />

THIS IS A BAD CAGE<br />

The Hagelin cipher machine 139

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

Saved successfully!

Ooh no, something went wrong!