The Playfair cipher is a method of cryptography invented in 1854 by English physicist Sir Charles Wheatstone (1802–1875). The encryption method was named for Wheatstone's friend, Lyon Playfair, who helped popularize the cipher by successfully lobbying for its official adoption by the British government.
All cryptography schemes are designed to conceal a message's meaning and maintain confidentiality in communications. The Playfair is a block cipher that disguises a message by substituting each pair of letters in the plaintext with a secondary pair of letters. Each unit or pair of letters is known as a digraph.
A keyword, usually only known to the sender and recipient, is written into a five-by-five square. Repeated letters are omitted. After the keyword is spelled out, empty blocks are filled with the rest of the letters of the alphabet in alphabetical order. The letters I and J are treated as the same letter and therefore, combined in the same block. The following example is a Playfair cipher decoded by Lord Peter Wimsey in Dorothy L. Sayers's Have His Carcase. The keyword is "Monarchy."
Enciphering the phrase, "We are discovered. Save yourself," involves several steps. First, the plaintext is
divided into two-letter groups. An X is added when there is an uneven number of letters.
WE AR ED IS CO VE RE DS AV EY OU RS EL FX
Next, locate the position of the two plaintext letters in the box matrix. Letters appearing in different rows and columns are replaced by the letter that is in the same row but in the other column; i.e., to encrypt WE, replace W with U, and E by G.
When a pair appears in the same row, as A and R does above, each letter is encrypted as the next cyclically appearing letter; i.e., AR becomes RM. The same rule of thumb applies when the pair is in the same column. In this example, IS would be encrypted as SX.
The enciphered phrase for Sayers's Playfair becomes:
UG RMK CSXHMUFMKB TOXG CMVATLUIV
In the event a double letter occurs, a bogus letter, such as an X, replaces the repeating letter. In order to decrypt the message, simply reverse the process.
The simplicity and reliability of this primitive code-cracking method made it extremely popular on the battlefield. The British employed the Playfair in the Boer War in addition to World War I. Several militaries relied on the Playfair as a back-up cipher during the Second World War. Lieutenant (and later, President) John F. Kennedy used the Playfair encryption method to send an emergency message after his PT-109 sank in the Solomon Islands in 1943.
█ FURTHER READING:
University of North Dakota. "The Cipher Exchange and Cipher Standards." < http://www.und.nodak.edu/org/crypto/crypto/.chap08.html#PLAYFA > (December 09, 2002).
Glyphworks. "Classical Cryptography." < http://storm.prohosting.com/~glyph/crypto/class_sub.shtml > (December 09, 2002).
NOVA Online. "The Playfair Cipher." November 2000. < http://www.pbs.org/wgbh/nova/decoding/playfair.html > (December 14, 2002).