The Enigma cipher machine was a device developed in Poland prior to
World War II. It allowed for, at the time, a reasonable level of
security in data transmission. It was thought at the time that it
was an unbreakable cipher, and as happens all too often, it wasn't.
The heart of the machine was a set of rotating wheels. These wheels
had contacts on the two sides around the edge that allowed electrical
contact to be routed through the wheels. Each letter was represented
on the wheels, and an electrical signal was passed through each of
the left hand side contacts for a given letter to a different right
hand side contact.
These wheels where then stacked side by side on
a common shaft and where then placed between a frame an a thing called
a "reflector". The reflector had electrical contacts around it's left
side, just like the wheels. But it differed in that instead of connecting
the right side to the left, it simply rerouted the left side signals
for a given letter position back to some other left side contact.
The machine worked by converting a key stroke into an electrical
signal that then went into a corresponding contact on the far left
frame. This then made contact with the first wheel, say A, and was
rerouted through the wiring of the wheel into say a T. The signal then
left the right side of wheel 1, to enter the left hand side of wheel 2
at position T. The signal would then map through wheel 2, starting at
position T and come out as position V. This would go on through three
or four wheels, depending on what time during the war you are talking
about, until it hit the reflector. The reflector would reconnect the
signal and ship it back through the wheel set until it came out of the
left hand side of wheel 1 in a position other than the one it came in
on. Because of the one to one mapping through all of the wheels, and
the reflector, this is guarenteed by the design.
Once out of the wheels, the signal would then go through a thing called
the plug board. This flipped pairs of characters around in a fixed
way. Later analysis of the Enigma machine proved this to be one of
the best features of the device. By forcing particular characters
to always be flipped in the last stage, it made the rotor selections
far harder to determine.
In any case, once the signal left the plug board, it entered an array
of lamps that were set behind letters to illuminate. The final operation
that the Enigma then performed was to rotate the wheels. It did this
in a fairly simple clock like motion (rotate the first wheel 26 times,
then rotate the next wheel once; when the second wheel had been rotated
26 times, rotate the third). This made the translation of two subsequent
characters operate off of different wheel settings, thus making it very
hard to decrypt the message.
Because of the reflector, if you put in a "C" and it comes out as a
"T" for any one wheel setting, you can also put in a "T" and get out
a "C". This was a simplicity that worked well for this machine. You
didn't have to care about whether you were encoding or decoding. You
just had to setup the machine right prior to the attempt.
The operation crew for this device usually consisted of three folks. One would
read (or receive it by Morse Code off of the radio) the input text to be encoded
or decoded and type it into the Enigma. One would read off the lamps and the
last person would write the resulting text down or transmit it via Morse Code to
the receiving party. This made duty in the signal corps fairly hazzardous,
in that to encode or decode any one message, there were three guys, all
heads-down working on the message. All of them had their hands full, and
as such, didn't have hands for weapons to defend themselves.
Each day, the Enigma operators had a setting for the machine to
start all messages on. This setting included which of the wheels
to use, where they should "start", and what the plug board settings
should be for the day and hour that you were transmitting the message.
Relying on this human interaction with the machine
helped break the Enigma cipher. Operators would get lazy, and as
they typically knew the guy on the other end of their message, they
would come to a mutual understanding on what they would simplify.
In any case, a group of mathemeticians at Blechy Park in England broke
the Enigma Cipher with a machine that they built called "the bomb".
It was basically a series of wheels that dealt with all of the perumutations
of the wheels. Given an Enigma machine with 3 wheels, the bomb used
5 wheels (one for each possible starting wheel), and each wheel's output
would then go to a set of 4 wheels (having removed the first one from
the resulting set) and when would try to do the whole thing over. The
British team used paper tape telegraph machines to print out the text
rather than the light pannels that the Germans used. Scores of people
would then stare at the paper tapes and would wait for reasonable German
words to come out. The first tape to indicate valid German would then
be referenced back to figure out what the settings for the original
Engima was that encoded the message. This would be recorded with the
original start time for further research.
This is where the Blechy Park team got some of their early breaks.
That human interaction between the German signal corps Enigma operators
came back to haunt them. The logs of what the starting state of the
Enigma machines was proved to indicate which German operators were
"simplifing" their machine's setups. Using the information about how
they simplified things, allowed the British team to zero in on the
starting state of a given Enigma machine's operational settings were
for any one given day and operator.
All of this, of course, is history. The Enigma cipher machine is now
a thing of antiquity. As an encryption mechanism, the Enigma is now
very out of date. Modern computers can easily do a brute force attack
on correctly encoded Enigma ciphers and come up with the plain text
rather easily. However, as one of the first encryption mechanisms used
in a warfare setting, the Enigma machine has the distinction of being
one of the most costly devices ever built.
Let's encode the message "Hello Sam". To be true to the
original Enigma machine, all letters must be upper case and if
any spaces or punctuation is needed, it must be spelled out.
In our case, our message would become "HELLOSAM".
Next, we would take one character at a time and pass them
through the wheels given below:
'H' would map to 7 and go into the first wheel.
'7' would become '18' going forward through wheel 1.
'18' would become '7' going forward through wheel 2.
'7' would become '24' going forward through wheel 3.
The reflector would convert '24' to '25'.
'25' would become '22' going back through wheel 3.
'22' would become '19' going back through wheel 2.
'19' would become '24' going back through wheel 1.
This would result in mapping 'H' into 'Y'.
Now we rotate wheel 1.
The resulting wheel settings look like:
Then we would encode "E". 'E' would map to 4 and go into the first wheel.
'4' would become '20' going forward through wheel 1.
'20' would become '21' going forward through wheel 2.
'21' would become '19' going forward through wheel 3.
The reflector would convert '19' to '18'.
'18' would become '14' going back through wheel 3.
'14' would become '24' going back through wheel 2.
'24' would become '15' going back through wheel 1.
This would result in mapping 'E' into 'P'.
Now we rotate wheel 1.
Continuing on in this vein, the resulting encoding of "HELLOSAM"
would be: "YPEKPWHV".
I would also like to point out here that each time you reload this
page, new wheels are generated and actual encryption occurs. However,
as I do not give any way to interact with what is encoded, this page
serves only as an educational tool.