Enigma demo: how it works
The machine was about the size of an old-fashioned typewriter, usually contained in a wooden box. The input was by way of a typewriter-style keyboard (with alphabetic keys only), and the output through a lampboard. For each key depressed on the keyboard, the encrypted (or, as we shall see, decrypted) corresponding letter would light up on the lampboard, for copying down and later transmission by Morsecode telegraphy or otherwise.
The core of the machine was a series of scrambler wheels. There were three wheels in early versions, later four, each one having 26 contacts on one side and 26 on the other, wired to each other in different ways so that, in one wheel, current flowing in through the A contact on one side, might exit through the Q contact on the other side, whereas in a different wheel, the wiring might go from A to F. In this way, each scrambler wheel represented a different substitution alphabet.
For each key depressed, the rightmost wheel would rotate one step, thus effectively providing a new substitution alphabet after each new character. At regular intervals, (once or twice per rotation), a latch on the wheel would cause the middle wheel to rotate one step, and equally, the middle wheel would eventually cause the lefthand wheel to rotate. (This is the same principle as with car odometers.)
When the current had passed through the three (or four) scrambler wheels, it would reach the contacts on the "reflector", a special, non-moving wheel which was wired in pairs, so that, for instance, if current came in through the U contact, it might exit through the P contact and vice versa. This was both a strength and a weakness with the Enigma. It was a strength because it meant that the same machine and the same setting could be used both for encryption and decryption - if you typed some clear text in with a certain setting, crypto text would come out which could then be turned back into clear text by the recipient simply by giving the machine the same settings and then typing in the crypto text. At the same time, it gave rise to a weakness in that, for any given position of the wheels, there would only be 13 discrete encodings - if an attacker knew that P=U then it was also certain that U=P.
From the reflector, the current passed back through the three (or four) scrambler wheels, following a different route (and the need for this gave rise to the other great weakness of the machine itself, namely that no letter could ever be encrypted as itself - in no position would L ever be encrypted as L). Then the current would pass into the lampboard and become encrypted output.
When the machine was bought by the German Armed Forces, they improved further on its security by adding a plugboard. The plugboard would allow the operator to connect any number of pairs of letters with cables, which provided a further substitution of letters by swapping them - if you connect S and K, for example, the effect would be to swap those two letters whenever they occur. With this, the current from a depressed key would pass first through the plugboard and then through the scrambler wheels, the reflector, back again through the scrambler wheels, and then through the plugboard once more before reaching the lampboard.
Further complication was added by the fact that there were up to eight (more for the four-wheel versions) different scrambler wheels to choose from, and any one of them could be placed in either of the three positions (though there were some limitations as to which could go where in the four-wheel versions); and there were also different reflectors to choose between. Each wheel had an outer "tyre", marked with the letters of the alphabet. But this tyre could be locked in any position relative to the contacts of the wheel, which added further variations. Finally, the wheels could be set in any starting position before encryption. With all these options, it was estimated that the Enigma could have 150,000,000,000,000,000,000 different settings - the equivalent of a 50-bit key in modern, computer cryptography terms.
|