Recent Articles



































Rotor machine



         


A rotor machine is an electro-mechanical encryption device whose primary component is the rotor, a rotating disk with electrical contacts on either side. Each rotor implements a substitution alphabet, and by changing the arrangement or positioning of the rotors, entirely new substitution alphabets can be easily arranged. The selection of which alphabet to use for encoding a particular letter of plaintext is handled mechanically by spinning the rotors, unlike a much smaller number of possible substitution alphabets provided for in such systems as the Vigenère cipher.

[Top]

Background

In classical cryptography, one of the earliest encryption methods was the simple substitution cipher, where letters in a message were systematically replaced using some secret scheme. Monoalphabetic substitution ciphers used only a single replacement scheme — sometimes termed an "alphabet"; this could be easily attacked using frequency analysis.

Somewhat more secure were schemes involving multiple alphabets, polyalphabetic ciphers. Because ciphers were normally implemented by hand, only a handful of different alphabets could be used; anything more complex would be impractical. However, using only a few alphabets left the ciphers vulnerable to refined versions of frequency analysis. The invention of rotor machines mechanised polyalphabetic encryption, providing a practical way to use a much larger number of alphabets.

[Top]

Mechanization

Imagine an electrical system with 26 switches attached to 26 light bulbs. When you turn on any one of the switches, the corresponding light bulb lights up. Now replace the switches with the keys on a typewriter attached to those switches, and label the bulbs with letters. Typing the letter "A" makes the bulb labelled "A" light up, and typing a message makes the bulbs light up in turn as the keys are pressed.

To turn this system into an encryption system, all one need do is change the wiring. Instead of a wire from the typewriter key for "A" running to the bulb labelled "A", run it instead to, say, X. Now typing in a message encrypts it, with zero effort on the operator's part.

The system just described is identical to the original single-alphabet substitution system, and has been entirely insecure since about 1000CE. The new idea in these machines was to place this scrambled wiring on the rotor, and then rotate it with a gear every time a letter was pressed. So while pressing "A" the first time would generate an "X", the next time it would generate a "J". Every letter pressed on the keyboard would spin the rotor and get a new substitution.

In effect, the rotors are generating a key themselves. Their algorithm being, "use the next substitution alphabet with every key press". Most of the 'key' is hidden in the wiring of the disk. All that is needed to communicate the key between two parties is to say where to set the rotor before pressing the first key. A single letter (or number) now generates a huge key mechanically – voila! the problem is solved.

Well almost. Depending on the size of the rotor, this may or may not be more secure than hand cyphers. If the rotor has only 26 positions on it, one for each letter, then all messages will have a (repeating) key 26 letters long. Although the key itself (mostly hidden in the wiring of the rotor) might not be known the methods for attacking these types of codes don't need that information. So while such a single rotor machine is certainly easy to use, it's no more secure than any other partial polyalphabetic cypher system.

But this too is easy to correct. Simply stack more rotors next to each other, and gear them together. After the first rotor spins "all the way", make the rotor beside it spin one position. Now you would have to type 26 x 26 = 676 letters (for English) before the key repeats, and yet it still only requires you to communicate a key of two letters/numbers to set things up. A key of 676 length isn't enough? Add another rotor, now you have a key 17,576 letters long. And so forth.

In order to be as easy to decipher as encipher, rotor machines were symmetrical. This makes sense if you consider how they work, if the current is sent from the battery (eventually) to the lamp, putting the current back in at the lamp end would reverse the circuit. Of course one cannot cause a typewriter key to "light up" (at least until recently), and in practice the rotors were initially reversed instead, thereby reversing the scrambling. Note that modern cryptography uses 'symmetrical' to mean that both cypher users must use the same key, not that the enciphering algorithm is run backwards to decrypt.

[Top]

History

The concept of a rotor machine occurred to a number of inventors independently at a similar time. The first were two Dutch naval officers, Theo A. van Hengel (18751939) and R. P. C Spengler (18751955) in 1915. Four other inventors also provided designs, although a little later.

In the United States Edward Hugh Hebern built a rotor machine using a single rotor in 1917. He became convinced he would get rich selling such a system to the military, the Hebern Rotor Machine, and produced a series of different machines with one to five rotors. Instead of becoming rich he instead went bankrupt in the 1920s, although he sold a small number of machines to the US Navy in 1931.

In Hebern's machines the rotors could be opened up and the wiring changed in a few minutes, so a single mass-produced system could be sold to a number of users who would then produce their own rotor keying. Decryption consisted of taking out the rotor(s) and turning them around to reverse the circuitry. Unknown to Herbern, William F. Friedman of the US Army's SIS promptly demonstrated a flaw in the system that allowed the cyphers from it, and from any machine with similar design features, to be cracked with enough work.

Another of the inventors was a Dutchman, Hugo Koch, who also filed a patent on a rotor machine in 1919. In Sweden, A Damm invented and patented still another rotor design about the same time.

The rotor machine was made famous by still another inventor, Arthur Scherbius, who also won a patent on a rotor cypher machine design and built his first Enigma machine (after the Greek word for riddle) in 1918. Enigma machines usually used three rotors, but most variants added a unique feature, the reflector. At the end of the stack of three rotors in some models was an additional rotor-like disk, this one wired such that the inputs were connected electrically back out to some other contact on the same side – like 'half' of a normal rotor. When current was sent into most of these machines it would travel through the rotors and out the other side to the lamps, but in the Enigma it was "reflected" back through the disks before going to the lamps. The advantage to this system was that there was nothing that had to be done to the setup in order to decrypt a message, the machine was symmetrical at all times. This feature was unique to the Enigma machines.

Scherbius joined forces with a mechanical engineer named Ritter and formed Chiffriermaschinen AG in Berlin before demonstrating Enigma to the public in Bern in 1923, and then in 1924 at the World Postal Congress in Stockholm. In 1927 Scherbius bought Koch's patents, and in 1928 they added a plugboard, essentially a non-rotating manually-rewireable fourth rotor, on the front of the machine. After the death of Scherbius in 1929 (in a horse carriage accident!), Willi Korn was in charge of further technical development of Enigma.

As with other early rotor machine efforts, Scherbius had limited commercial success. However, Admiral Jackie Fisher and Winston Churchill both published accounts in the '20s which revealed that the British had been routinely reading German messages during WWI. As well, political considerations twice led Ministers in the British government to reveal that Soviet messages had been read by the British. Both the Germans and Soviets were determined to make sure that this didn't happen again. The German military accelerated experiments already underway to change to rotor machines. The German Navy had been using an Enigma variant for some years, and the German Army began to use a different variant about 1932. The Scherbius design had won the competition in Germany. The Soviets also reviewed their cryptographic efforts and Soviet use of the one-time pad in its espionage operations seems to have begun around this time. The German Foreign Office had been using the one-time pad for some traffic since 1919.

The Enigma (in several flavors) was the rotor machine Scherbius' company, and its successor, Heimsoth & Reinke, supplied to the German military and to such assorted civilian agencies as the Nazi party security organization, the SD. The German Army version was the Enigma the Poles broke in the early '30s not long after it was first used. they passed their progress on to the French and British in August of 1939, and the British/French continued to break German Army Enigma -- along with Luftwaffe Enigma traffic -- until French cryptanalysis (at Station PC Bruno) was shut down. The British continued alone, and extended the work to German Naval Enigma traffic, most especially to and from U-boats during the Battle of the Atlantic.

A software implementation of the Enigma was used in the crypt command that was part of early UNIX operating systems. It was among the first software programs to run afoul of U.S. export regulations which classified cryptographic implementations as munitions. The link given below contains a reference to an electronic kit, implementing an Enigma rotor machine.

During WWII, both the Germans and Allies developed additional rotor machines. The Germans developed the Fish cyphers, one by Lorenz Electric and another jointly by Siemens and Halske, and the Allies the Typex (British) and the SIGABA (American). During the War the Swiss began development on an Enigma improvement which became the NEMA machine which was put into service after WWII. There was even a Japanese developed variant of the Enigma in which the rotors sat horizontally; it was apparently never put into service. the Japanese Purple cypher machine was not a rotor machine, being built around electrical stepping switches, but was conceptually similar. The link below contains images of several of these machines.

[Top]

List of rotor machines

[Top]

References

[Top]




  View Live Article   This article is from Wikipedia. All text is available under the terms of the GNU Free Documentation License