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

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

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

9.4. PLAYFAIR 177<br />

Playfair Ciphers: Pick a keyword. Using the Keyword Mixed method<br />

Section 5.2 to mix the alphabet, arrange the the alphabet in a 5 × 5 array,<br />

considering i and j to be the same letter.<br />

To encipher, the plaintext is replaced two letters at time using the following<br />

rules.<br />

1. If the letters are in the same column, replace each by the letter below<br />

it.<br />

2. If the letters are in the same row, replace each by the letter to its<br />

right.<br />

3. If the letters are in neither the same row or column, then use them to<br />

form a rectangle. The individual letters are replaced by the opposing<br />

corners <strong>of</strong> the same height, i.e., the opposing corner in the same row.<br />

(Notice that we must pretend that leaving the bottom <strong>of</strong> the array to be<br />

entering its top, and leaving the right-hand-side to be entering its left-handside.)<br />

Deciphering is simply the opposite: replace by the letters above, to the left,<br />

and by the opposing corners.<br />

For example, if we use the alphabet in its usual order (with J omitted) the<br />

array is<br />

A B C D E<br />

F G H I K<br />

L M N O P<br />

Q R S T U<br />

V W X Y Z<br />

Then examples <strong>of</strong> each <strong>of</strong> the three enciphering steps are as follows:<br />

1. bm→GR, uz→ZE<br />

2. lo→MP, gk→HF<br />

3. ls→NQ, er→BU<br />

Similarly, here are examples <strong>of</strong> the three deciphering steps.<br />

1. LA→fv, JO→dj<br />

2. QU→ut, CE→bd<br />

3. TW→ry, LI→ <strong>of</strong><br />

If there are repeated letters in a pair, insert a null, <strong>of</strong>ten x, to break them up.<br />

So balloon becomes ba lx lo on. Notice that oo is naturally broken, so no x<br />

is needed. If the message contains an odd number <strong>of</strong> letters either send the last<br />

letter un-enciphered, or add a final null letter before enciphering.

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

Saved successfully!

Ooh no, something went wrong!