Enigma Machine Tutorial
The Enigma machine began life in 1923 as a commercial product produced by a German named Arthur Scherbius aimed at businesses with a need for secure communication. It was a simple device to use, after setting it up, the operator types in the plaintext of his message. Each time a key is pressed, a letter on the lampboard is illuminated corresponding to the cyphertext. The operator then simply notes down the cyphertext letter and carries on. The commercial Enigma was based on a simple principle shown in the diagram below.
The user types a message in using the keyboard. Each key pressed energises one of 26 'letter' circuits within the machine. Power is passed from the keyboard to one of 26 end contacts in the scrambler unit. Power then passes through the three rotors, each being wired so that it changes the letter to another one. The machine has now applied a scrambling operation to the original letter. The 'wiring' of the machine is altered after each letter by rotating the first rotor by one position (and the next after 26 letters), thus pressing the same plaintext letter twice is unlikely to result in the same cyphertext letter.
An important factor in the Enigma's design was ease of use. Applying a simple 'one way' scrambling operation as described above has an important disadvantage: to decrypt the message it would be necessary to reconfigure the machine so as to feed power from the keyboard to the opposite end of the rotors. This would both make the engineering of the machine more difficult and more importantly, complicate its use and make it more error prone.
The Enigma solves this problem by adding a 'reflecting' rotor after the circuit passes through the rotors. This connects each end contact to another, thus routing the circuit back through the three rotors to one of the 26 input contacts. The result is that the machine becomes both an encrypting and a decrypting machine of the same message once the initial settings have been made.
While this solution is simple and provides the machine with an elegant simplicity it is also the cause of one of the major flaws in the scheme. Introduction of the reflecting rotor also introduces the restriction that no plaintext letter can ever be encrypted to itself.
The most significant addition to the commercial machine was the addition of a plugboard or 'Stecker'. This device allowed individual pairs of letters to be swapped, thus causing extra substitutions in addition to those made by the rotors. An important feature of the Stecker was that if, for example, an 'A' was swapped with a 'Z', then the converse was also true, so a 'Z' became an 'A'. This preserved the simplicity of use of the machine and also preserved the key weakness that a letter could never be encrypted to itself.
The design of any worthwhile encryption system assumes that the 'enemy' has a complete knowledge of how the system works, so knowing the make-up of the machine (and even producing reproductions of it) is not enough. The Enigma relied for its security on the fact that it could be set up to any one of a huge number of different configurations (settings or 'states') at the beginning of a message:-