Chiffriermaschine · 1918 – 1945

ENIGMA

The cipher machine that kept a war’s secrets — rebuilt to the last wire. Type on it. Watch the current race through rotors, reflector and plugboard. Then take it apart.

Klartext
Geheimtext
  • 158,962,555,217,826,360,000possible starting settings
  • 0letters that ever encrypt to themselves
  • 1 → 1same machine decrypts what it encrypts

01 · The machine

Sit at the Enigma

Use your keyboard or tap the keys. Every press turns the rotors first, then sends current on its journey — so the same letter never gives the same answer twice in a row.

A–Z type · ⌫ undo · ↑↓ turn hovered rotor

02 · Inside the machine

One keypress. Eleven transformations.

This is the same machine, cut open. Press any letter: the rotors step, then current flows in through the plugboard and all three rotors, bounces off the reflector, and runs back out by a different route to light a lamp.

1

Rotors step

Before any current flows, the right rotor advances one notch. When a notch lines up, it also carries the next rotor along — an odometer with a famous quirk.

2

Plugboard swap

Up to ten cables swap pairs of letters. A cable between A and T turns every A into T (and T into A) — on the way in and on the way out.

3

Three rotors

Each rotor is a scrambled substitution wired inside a disc. Current passes right → middle → left, and because the discs turn, the substitution changes with every letter.

4

The reflector

A fixed plate pairs the 26 letters and sends the current back through the rotors on a different path. It makes Enigma reversible — and forbids a letter from becoming itself.

5

Lamp lights

The return trip (left → middle → right, then the plugboard again) ends at a lamp. The operator reads it off and writes it down. Press → lamp: about a blink.

03 · Rotors & stepping

A wheel that rewires itself

A rotor is a disc with 26 contacts on each face, joined by 26 scrambled wires. Turn the disc and the same contact leads somewhere new. Pick a rotor, turn it, and follow one contact.

Outer letters are fixed contact positions on the right face; inner letters are positions on the left face. The bright wire is the one currently carrying a signal that enters at A (click any outer letter to change it). Turn the rotor and watch the answer change.

The odometer — and its double step

Only the right rotor moves on every keypress. Notches cut into the alphabet rings let pawls push the neighbouring rotor along. Because the middle rotor’s pawl also pushes the middle rotor itself, it steps twice in a row once in a while.

Right rotor steps on every keypress.

04 · How an operator used it

From key sheet to radio message

An Enigma is only as secret as its settings. The machine itself was assumed to be known to the enemy — what mattered was the key. Here’s the routine, in six steps.

  1. 1

    Read today’s key sheet

    Every network had a monthly sheet listing, for each day, the rotor order (Walzenlage), ring settings (Ringstellung) and plugboard pairs (Steckerverbindungen). Everyone on the net used the same day key.

  2. 2

    Fit the rotors & set the rings

    Three of the five (later eight) rotors go on the spindle in the listed order. The ring (alphabet ring) is rotated relative to the wiring core and locked — it moves the turnover point without changing the start letter you see.

  3. 3

    Plug the cables

    Ten cables go into the Steckerbrett on the front, each joining two letters. Six letters stay unplugged. This single step multiplies the number of possible keys by about 150 trillion.

  4. 4

    Choose a ground setting & message key

    The operator picks three random letters as the Grundstellung, turns the rotors to them, then invents a random message key and types it once. The three lamp letters are the encrypted message key (the indicator).

  5. 5

    Turn to the message key & type

    Rotors go to the message key letters, and the message is typed one letter at a time while a second person writes each lamp. Spaces were usually sent as X.

  6. 6

    Transmit in five-letter groups

    The ciphertext goes out in Morse with the ground setting and encrypted message key in front. The receiver sets the same day key, reverses steps 4–5, and reads plaintext. That’s the whole trick: same machine, same key.

Two reasons it felt unbreakable

158,962,555,217,826,360,000

settings for three of five rotors and ten cables — before counting ring settings. Nobody could try them all, by hand or by 1940s machinery.

Every letter, a new alphabet

With three rotors the substitution alphabet repeats only after 16,900 letters (26×25×26, because of the double step). Short messages never repeat — no frequency analysis.

05 · How it was broken

The flaw hiding in the reflector

The reflector that made Enigma convenient also made it impossible for any letter to encrypt to itself. Codebreakers turned that one tiny rule into a weapon.

Try to make an A come out as A

Hold down the same key for a thousand presses. The machine will scramble it however it likes — except into itself.

—

Sliding a crib

Bletchley Park often knew (or guessed) a fragment of plaintext — a crib — because messages started the same way (WETTERBERICHT, “weather report”) or ended with the same phrase. Slide the crib along the ciphertext: any position where a crib letter sits above the same cipher letter is impossible. That cuts the search before a Bombe even starts.

1932

Polish mathematician Marian Rejewski reconstructs the wiring of the Army Enigma using permutation theory and a few leaked documents.

1939

Weeks before war, the Poles hand their replicas and methods to French and British intelligence at Pyry, near Warsaw.

1940

At Bletchley Park Alan Turing and Gordon Welchman build the electromechanical Bombe, which tests rotor settings against a crib at speed.

06 · A short history

From a commercial gadget to the war’s greatest secret

  1. A patent for a rotor machine

    Engineer Arthur Scherbius patents the idea; commercial Enigmas follow in the early 1920s, sold to banks and businesses.

  2. The military takes over

    The German Navy (1926) and Army (1928) adopt Enigma. A plugboard is added, and the three-rotor Enigma I becomes the standard Wehrmacht machine.

  3. Poland breaks it

    Marian Rejewski, Jerzy Różycki and Henryk Zygalski of the Polish Cipher Bureau read Enigma traffic, building on documents supplied through French intelligence.

  4. Pyry

    With invasion looming, the Poles reveal their methods and replicas to British and French delegations.

  5. Bletchley Park & the Bombe

    Turing and Welchman develop the Bombe. The first one, Victory, is running in March 1940. Hundreds follow.

  6. The fourth rotor

    U-boats switch to a four-rotor “M4” Enigma. Bletchley goes dark on naval traffic for about ten months before breaking it again.

  7. The secret keeps

    Allied use of “Ultra” intelligence stays classified for decades; it became public only in the 1970s.

Accuracy notes

This simulator implements the Wehrmacht Enigma I with rotors I–VIII, reflectors B and C, ring settings, the plugboard and the real stepping mechanism including the double step. It reproduces standard published test vectors (for example, rotors I-II-III, reflector B, all at A, turns AAAAA into BDZGO). The four-rotor naval M4 is not modelled.