How to make an enigma (or: How to turn HELLO WORLD into FJHJETGZBBM)

The past two weeks I've read lots about encryption, cipher and last (but not least) the Enigma machine. During this whole project, I realized that making an enigma can't be that hard. It wasn't :)

Although making an actual Enigma machine can be a bit tricky (but would definitely be an awfully cool science project), the basics aren't all that hard.

If you haven't yet read the writeup on Enigma, I suggest you do so right now.

### What you need

Paper. Scissors. And a printer. Print this node out, and cut out the following (between the groups of letters):

```  A   1  2  3  REF
+---+ -- -- -- --
|A  | AQ MZ QO QR
|B  | BW NX AL WF
|C  | CE BC ZP EC
|D  | DR VV XI RE
|E  | ET CB SK TD
|F  | FY XN WM YX
|G  | GU ZM EN UW
|H  | HI AL DJ IS
|I  | IO SK CU OZ
|J  | JP DJ VY PQ
|K  | KA FH FH LA
|L  | LS GG RB KT
|M  | MD HF TV JB
|N  | NF JD GG HG
|O  | OG KS BT GV
|P  | PH LA NR FU
|Q  | QJ QP HF DH
|R  | RK WO YC SY
|S  | SL EI UX AJ
|T  | TZ RU JD ZN
|U  | UX TY ME XI
|V  | VC YT KW CM
|W  | WV UR IS VL
|X  | XB IE OZ BK
|Y  | YN OW LA NO
|Z  | ZM PQ PQ MP
+---+

```

### How to make your enigma

Okay. Print out the list above three times. Then you cut the four lists into strokes, and tape them together, so you have four long strokes. Put them next to each other on the table. You might want to glue the first stroke (marked A) and the last stroke (marked REF) to a piece of paper. The three middle strokes need to be able to move up and down between the A and the REF.

A - This is your "entering" keyboard. This is where you enter your message. In our case, we are going to encode "HELLO WORLD"

1 - This is your first code wheel

2 - This is your second code wheel

3 - This is your third code wheel

REF - this is your reflector.

Today, we are going to use wheel order 213 (that means put stroke 2 first, then stroke 1, then stroke 3), and starting setting FHR

To align your wheel so you are ready to start, first put your strokes in the correct order, and then align your first stroke's F with the second stroke's H with the second stroke's R. All of this you will have to align with the A on your entering keyboard

Now, we are going to write HELLO WORLD.

1 - Press H on your pad. From the H, you go straight across to your left wheel (that should be wheel number two). As you can see, you are entering the left wheel on W. Find the W on the right coloumn of your left wheel.

2 - Good. You are now on the right coloumn of your left wheel, and looking at the W. Right across (on the left coloumn of the middle wheel) you see a V. Find the V on the right coloumn of the middle wheel.

3 - Across from the V, you should now see a Q. On the right wheel, in your right coloumn, find your Q (it is on the bottom), and go into your reflector on the Q.

4 - Find the Q on the right side of your reflector. This time, you are going back through the wheels again, so you are now going from the right Q in the reflector.

5 - This should bring you to the E of the right wheel. Now, find the E on the left side of the right wheel

6 - From the E on the left side of the right wheel, you go across. Ironically enough - you meet an E on the right side of the middle wheel

7 - From the left E on your middle wheel, you go across to the left, where you meet the L on the left wheel.

8 - From the right L on the left wheel, you go right across into the area where you tapped in your H.

9 - Your H from Hello world has now been encyphered, and has become an F.

How the real encryption begins

Okay, you have now used a very complicated way of turning an H into an F. But this whole system is useless, if you just remap the keys (you might as well have picked a regular table, as is used in ROT-13.

The big trick, therefore, is that after the first letter has been encrypted, we rotate the right wheel one notch down. After another letter is done, you go another notch down. If your right wheel reaches all the way down (i.e your Q on wheel number 3 aligns with the A on your "keyboard"), move your middle wheel one notch down, and keep going.

With some computer power, you will obviously be able to hack this encryption - But in 1940, when computers were unheard of, this was a pretty secure system, if it hadn't been for those silly germans botching their own encryption all the time.

Decrypting

When decrypting messages, do the exact same thing, but the other way around:

• Set your Enigma in the initial setting
• Enter the first letter
• Write down whatever you get
• Repeat step 2 and 3
• ... Congratulations :)

HELLO WORLD

HELLOXWORLD (Xes are used as spaces, to make the decrypting even harder. Use two Xes for period, and three Xes for new paragraph) becomes:

# FJHJETGZBBM

when you use the wheel order 213 and the initial setting of FHR