Book cipher explained

A book cipher is a cipher in which each word or letter in the plaintext of a message is replaced by some code that locates it in another text, the key.

A simple version of such a cipher would use a specific book as the key, and would replace each word of the plaintext by a number that gives the position where that word occurs in that book. For example, if the chosen key is H. G. Wells's novel The War of the Worlds, the plaintext "all plans failed, coming back tomorrow" could be encoded as "335 219 881, 5600 853 9315" — since the 335th word of the novel is "all", the 219th is "plans", etc. This method requires that the sender and receiver use the exact same edition of the key book.[1]

This simple version fails if the message uses a word that does not appear in the text. A variant that avoids this problem works with individual letters rather than words. Namely each letter of the plaintext message would be replaced by a number that specifies where that letter occurs in the key book. For example, using the same War of the Worlds book as the key, the message "no ammo" could be encoded as "12 10 / 50 31 59 34" since the words with those positions in the novel are "nineteenth", "of", "almost", "mortal", "might", and "own". This method was used in the second Beale cipher. This variant is more properly called a substitution cipher, specifically a homophonic one.

Both methods, as described, are quite laborious. Therefore, in practice, the key has usually been a codebook created for the purpose: a simple dictionary-like listing of all the words that might be needed to form a message, each with the respective code number(s). This version is called a code, and was extensively used from the 15th century up to World War II.

Choosing the key

The main strength of a book cipher is the key. The sender and receiver of encoded messages can agree to use any book or other publication available to both of them as the key to their cipher. Someone intercepting the message and attempting to decode it, unless they are a skilled cryptographer (see Security below), must somehow identify the key from a huge number of possibilities available.In the context of espionage, a book cipher has a considerable advantage for a spy in enemy territory. A conventional codebook, if discovered by the local authorities, instantly incriminates the holder as a spy and gives the authorities the chance of deciphering the code and sending false messages impersonating the agent. On the other hand, a book, if chosen carefully to fit with the spy's cover story, would seem entirely innocuous.The drawback to a book cipher is that both parties have to possess an identical copy of the key. The book must not be of the sort that would look out of place in the possession of those using it, and it must be of a type likely to contain any words required. Thus, a spy wishing to send information about troop movements and numbers of armaments would be unlikely to find a cookbook or romance novel useful keys.

Using widely available publications

Dictionary

Another approach is to use a dictionary as the codebook. This guarantees that nearly all words will be found, and also makes it much easier to find a word when encoding. This approach was used by George Scovell for the Duke of Wellington's army in some campaigns of the Peninsular War. In Scovell's method, a codeword would consist of a number (indicating the page of the dictionary), a letter (indicating the column on the page), and finally a number indicating which entry of the column was meant. However, this approach also has a disadvantage: because entries are arranged in alphabetical order, so are the code numbers. This can give strong hints to the cryptanalyst unless the message is superenciphered. The wide distribution and availability of dictionaries also present a problem; it is likely that anyone trying to break such a code is also in possession of the dictionary which can be used to read the message.

Bible cipher

The Bible is a widely available book that is almost always printed with chapter and verse markings making it easy to find a specific string of text within it, making it particularly useful for this purpose; the widespread availability of concordances can ease the encoding process as well.

Security

Essentially, the code version of a "book cipher" is just like any other code, but one in which the trouble of preparing and distributing the codebook has been eliminated by using an existing text. However this means, as well as being attacked by all the usual means employed against other codes or ciphers, partial solutions may help the cryptanalyst to guess other codewords, or even to break the code completely by identifying the key text. This is, however, not the only way a book cipher may be broken. It is still susceptible to other methods of cryptanalysis, and as such is quite easily broken, even without sophisticated means, without the cryptanalyst having any idea to what book the cipher is keyed.[2]

If used carefully, the cipher version is probably much stronger, because it acts as a homophonic cipher with an extremely large number of equivalents. However, this is at the cost of a very large ciphertext expansion.

Examples

In fiction

See also

Notes and References

  1. Book: Changda Wang . Shiguang Ju . Book Cipher with Infinite Key Space . 10.1109/ISISE.2008.273 . 2008 International Symposium on Information Science and Engineering . 456 . 2008 . 978-0-7695-3494-7 . 15768123 .
  2. Book: Yardley, Herbert O. . The American Black Chamber . . 1981 . 0-345-29867-5 . New York . 2023-02-13 . 1931 . registration.
  3. News: Bell . Chris . Cicada 3301 update: the baffling internet mystery is back . . https://web.archive.org/web/20140108022102/http://www.telegraph.co.uk/technology/internet/10555088/Cicada-3301-update-the-baffling-internet-mystery-is-back.html . 8 January 2014 . live .