NEMA cryptographic machine
NEMA (short for "Neue Maschine") is an electromechanical encryption machine developed by Zellweger AG (Uster, Switzerland) during the Second World War and replacing the famous German Enigma. The machine is also known as TD and NEMA Modell 45.
At first glance, the machine had 10 rotors, but only 5 of them were connected by an electrical circuit. Also 4 out of 5 were coding rotors with 26 pins on each side. And the fifth disk is reflective, which during encryption could move (unlike Enigma, where the reflector was fixed).
NEMA consisted of a 26 letter (AZ) keyboard for entering open messages, as well as 26 light bulbs highlighting the desired letters of the ciphertext. But compared to Enigma, NEMA had additional switches between letters and numbers. They were used to connect to an electronic printing device. NEMA was attended by design improvements, such as irregular incremental rotation of the encryption rotors (by adding additional wheels). Hacking the cipher was especially difficult.

The development of the NEMA machine took place from 1941 to 1943 by a team of specialists led by Berne instructor Arthur Alder (Captain Arthur Alder). The composition of the developers included: Hugo Hadwiger, professor of analytical mathematics, Heinrich Emil Weber, professor of mathematics, and Paul Glur.
The first NEMA prototype was introduced in early 1944, but it received approval only a year later (after making several modifications and improvements). In 1946, the production of machines began. And the model came into operation only in 1947, which was somewhat late for military affairs. NEMA was used by the Swiss Army and the Ministry of Foreign Affairs (Diplomatic Service) in the post-war years, until it was replaced by more advanced encryption devices such as Hagelin and Gretag.
NEMA in detail:






Control
NEMA was in a black metal case-suitcase with a leather carrying strap and a cylinder lock on one side. All the necessary and additional components, such as a panel with light bulbs, a network cable, additional rotors and other accessories, were placed in the upper case cover.
Detailed diagram of the NEMA machine:

NEMA Models
The NEMA cryptographic machine was made in three basic types of models: Training, Military and Machines of the Ministry of Foreign Affairs. Despite the external identity and similarity of most of the operations of these models, some significant differences made the machines opposite in action.
Training machine
This model was used to train operators. To avoid the risk of data leakage about the machine and the principles of its operation, the training instance was different from the actual military model. Most of the surviving NEMA are of this type, as they have been used for quite some time and intensively for training. In German, the model is known as Schulmaschine (from German - a school car). The sample has a label:
Nur für Schulen und Kurse abgeben
A remettre uniquement aux écoles et cours
A solo uso di scuole e corsi
War machine
This model has remained classified for a long time. Military samples were slightly different in operations, had additional rotors (E and F), which were in cylindrical containers in the lid of the case. And the markings on the stepped rotors were different. Since NEMA was created after the war, it was only occasionally used for testing and remained in stock for many years. In German, this machine is known as the Kriegsmobilmachungs-Maschine or K-Mob-Maschine. The NEMA military model is a very rare specimen that can be recognized by its label:
Nur bei Kriegsmobilmachung abgeben!
Ne délivrer qu'en cas de mobilizationation guerre!
Da consegn. solo in caso di mobilitazione di guerra!
Foreign Ministry Machine
This version of NEMA was used exclusively by the Swiss Ministry of Foreign Affairs (Diplomatic Service). As far as we know, cars of this model have never been shown to the public. But it was found that the "diplomatic" NEMA was produced with different speed rotors and discs, as well as a differently configured step mechanism.
Principle of operation
NEMA's work was much like Enigma's work. Only in the Swiss car there was no patch panel. Instead, the number of notches was increased on the rotors. When you press the keyboard key, the circuit is closed. From a 4.5V battery, current passed through various circuits and as a result turned on one of a set of bulbs displaying the desired letter of the code. The constant change in the electrical circuit made it possible to create a multi-alphanumeric substitution cipher. This made it more stable and reliable. Unlike Enigma, NEMA's rotor movement mechanism was more complex.

NEMA used a reflector connecting pairs of wires together. Its presence was guaranteed by involution, that is, that decryption was the same as encryption.
For a more detailed study of the operation of 10 NEMA coding rotors, it was necessary to lift the hinge cover (to the left of the yellow label). Current flowed to the discs through the input rotor (ETW), the one that is red. All discs were marked - yellow letters of the alphabet.

The extreme disk on the right is the reflector (UKW), used as a reflector and consisted of 26 static contacts. Between the reflector and the input rotor were four pairs of intermediate disks. Each pair consisted of an electric coding rotor with 26 contacts on both sides and a mechanical wheel that controlled the movement of the rotor. Each electric disk could be combined with any of the step rotors. The pin and flat pins matched the letters in the alphabet. In contact, the contacts of adjacent rotors closed the electric circuit. Inside the rotor, each pin contact was connected to one of the flat ones. Each rotor had its own connection order.

The red lever was used to move the rotors.

After opening the lid, the lever should have been extended fully.

A drum with rotor pairs could be pulled out of the NEMA. With the exception of the input rotor, which was fixed and remained in the car.


In addition to the input, all rotors were placed on the spindle.

Disassembled rotor:

Step motion of rotors
The stepwise movement of the NEMA rotors took place in a complex manner. The rotors were moved using narrow and wide spindles and dogs. The upward movement moved the rotor one step. As a result, he only moved backward ( Z → Y → X → W , etc.).

As an additional level of complexity in the design, four regulation screws were used.

Adjustment of such screws required special tools and training. A similar configuration was used by military vehicles.
Cipher key
When choosing a key for the NEMA cipher, we should consider the internal and foreign keys. The internal key determined which stepped rotors are connected to the encryption disks. For example:
15-C / 12-A / 14-D / 13-B
The foreign key determined the initial position of the rotor at the beginning of the message. For example:
BXLRRTVYLZ
The starting position changed after moving the lever to the left to the last position. It was possible to move all ten rotors back and forth, choosing the right key.
Most keys were stored only for some time (usually about a day). For new messages, the new starting positions of the rotors were also asked. They did this in order to secure the cipher as much as possible. Indeed, if there were a sufficient number of messages sent with identical settings, a competent cryptanalyst (who also carefully studied several messages) could use a frequency analysis to select the cipher for the messages. It is worth recalling the principle of the initialization vector, where a similar idea was used. Together with the cryptogram, the initial positions were sent, before the encrypted text. This principle was called the “indicator procedure”. Actually, such weaknesses helped to succeed with breaking Enigma code.
The rotor produced a fairly simple type of encryption: an elementary replacement cipher, in which elements of the original plaintext were replaced with encrypted text in accordance with the requirements.
Calculating the total number of possible starting positions was relatively simple. If a military machine was taken, then there were 6 cipher rotors (AF) of which 4 were in the car. The output was 360 possible combinations of rotors (6 × 5 × 4 × 3) . The same thing happened with stepped rotors (360 variations). The calculation of the total number of possible starting positions of 10 rotors was 26 10 .
The total number of possible settings was calculated by the formula:
360 × 360 × 26 10 ,
which, in total, yielded:
12,359,619,140,000,000,000

Encryption and decryption of messages on NEMA could be read by letter using the lamp panel, which, if necessary, was connected to the machine.

On July 9, 1992, the NEMA cryptographic machine was officially declassified. A few years later, on May 4, 1994, training and operational NEMAs were put up for sale. As a result, the models joined the ranks of acquisitions of encryption machine collectors.