Fri. Aug 12th, 2022
    Enigma Machine That Cracked the Nazi Secret Code

    What is the Enigma machine?

    Enigma is an electromechanical rotor machine used for the encryption and decryption of secret messages. Which means it uses a combination of mechanical and electrical parts. The mechanical part is made up of the keyboard, the various “rotors” arranged along an axis, and a mechanism rotating one or more of the rotors each time a key is pressed. The exact mechanism varies, but the most common form is where the rotor on the right side rotates each time a key is pressed and the neighboring rotors are regularly moved, similar to the operation of an odometer.

    The continuous movement of the rotors allows different cryptographic transformations to be obtained with each press of a key. The electrical part of the device consists of a battery connecting the keys of the keyboard to lamps. When one of the buttons is pressed, one of the lamps lights up. For example, when a message begins with the sequence ANX…, the operator presses the A key and the Z lamp could come on; in this case, Z is the first letter of the ciphertext. The operator then encrypts the letter N in the same way, and so on for the following letters.

    Despite like typewriter appearance, it’s not only played a pivotal role in WWII, but also drastically advanced the history of computing and Artificial Intelligence.

    This machine was first marketed in Europe in the early 1920s. Of German origin, it was invented by Arthur Scherbius for commercial purposes. The objective is to protect the exchange of information between banks using encryption considered at the time to be indecipherable. From 1923, many variations of this machine will be marketed in Europe and around the world. The name “Enigma” will then be used generically to designate this family of machines. Thus, before becoming, thanks to Turing, a symbol of decryption in the hands of the Allies during the war, Enigma was above all an effective tool for securing communications.

    Who cracked the Enigma code?

    Alan turing.
    Computer genius and hero of WWII, Alan Turing is famous for decrypting the encrypted communications of the German military by defeating Enigma, the encryption machine used by the Nazis, deemed inviolable.

    How did Turing break Enigma?

    The Nazis encoded their messages with machines that swapped letters typed on the keyboard. The model used by the navy was cracked in 1942 by the English with the help of Alan Turing.

    Enigma encrypts information by passing an electric current through a series of components. This current is transmitted by pressing a letter on the keyboard; he crosses a complex network of wires and then lights a lamp which indicates the encrypted letter. The first component of the network is a series of adjacent wheels, called “rotors,” which contain the electrical wires used to encrypt the message. The rotors rotate, altering the complex configuration of the array each time a letter is typed. Enigma usually uses another wheel, called a “reflector”, and a component called a “patch panel”, which further complicates the encryption process.

    How to decode Enigma?

    To decrypt a message, you must either have an Enigma machine absolutely identical to the one used by the sender for the encryption of this message, and that this machine be set in the same way, or have a thorough knowledge of the extraordinarily complex operation of this machine, which few people were capable of, even at the British base at Bletchley Park. On the other hand, once the daily encoding key has been discovered, all the messages exchanged on that day by the network concerned can finally be very quickly decrypted.

    How Enigma works?

    The principle of operation of the Enigma is both simple and clever. Each time you press a letter, an electrical circuit is closed, and a bulb lights up which corresponds to the coded letter. Which circuit is closed depends on the position of the rotors. With each letter struck, one or more of the movable rotors rotates, changing the substitution that will be made at the next key pressed. In addition, the encryption is reversible: if by typing A you code D, if you had typed D, you would have coded A. Thus, if the German command and the submarine have the same starting setting, it suffices to operator of the submarine to type the coded message directly to get the clear message. The Germans had therefore distributed in their services code books allowing the machines to be updated every day at midnight, by the initial position of the rotors. These code books were valid for one month.

    The number of keys is gigantic (around 1020), and the Germans have complete confidence in the Enigma machine, of which they will manufacture 100,000 copies. Knowing and seeing everyone, they will exchange encrypted radio communications, convinced that the Allies will never understand them.

    Number of possible keys

    There are three things to know to be able to encode a message with the Enigma machine.

    the position of the 6 connection board plugs: First, you have to choose 12 letters out of 26. This is the number of combinations of 12 out of 26, ie 26! / (12! 14!). Now, you have to choose 6 pairs of letters among 12, that is to say 12! / 6 !, and since the pair (A, D) gives the same connection as the pair (B, A), we must again divide by 26. We find finally 100,391,791,500.
    the order of the rotors: there is as much order as there are ways of ordering 3 elements: 3! = 6.
    the initial position of the rotors: each rotor having 26 elements, there are 26 * 26 * 26 = 17576 choices.
    We multiply all that, and we get more than $ 10 ^ {16} $ possibilities, which is huge for the time!

    It is important to note that the permutations employed in rotors and reflectors cannot be considered secret. Indeed, all the machines use the same ones, and it is therefore enough to have one available. The British, for example, recovered one during the war from a sunken submarine. This is an illustration of a general principle in cryptography, the so-called Kerckhoffs principle, which states that all the secret must reside in the secret encryption and decryption key, and not in any confidentiality of the algorithm (here of the machine ) which cannot be reasonably guaranteed.

    Polish advances

    Poland was resuscitated in 1919 by the Treaty of Versailles. Fearing its German neighbor (and rightly so!), It has a very efficient number service, and is attentive to German communications. Polish intelligence manages to get hold of a civilian Enigma machine and understand how it works. Unfortunately, the rotors of the military machines were different, and impossible to reconstruct.

    It is first of all a betrayal which will help the Poles, that of Hans-Thilo Schmidt. He is the brother of Rudolph Schmidt, who heads the German Army Signal Corps and is the one who imposed the Enigma machine. Having resentment towards his brother and the fatherland (perhaps because he himself was removed from the army after the armistice of 1918), Hans-Thilo Schmidt sold in November 1931 to a French secret agent named Rex the shots of military version of Enigma. The French, who then have all the keys in hand, do not make a copy of the Enigma machine, but it provides the documents to the Poles.

    They did a remarkable job, initiated in particular by the young mathematician (23 years old) Marian Rejewski. By comparing the messages sent the same day, he manages to reconstruct the rotors used in the military version of the Enigma, and to make a copy. Thanks to an additional collective work of one year, an office made the table of the initial positions, and an automated machine, called “The Bomb”, made it possible to automate the decryption. Thus, by the mid-1930s, Poland had methods of deciphering German messages.

    In 1938, the Germans changed the protocol for sending their messages, and above all, they reduced the number of rotors of their Enigma from 3 to 5. Poland is losing contact. Faced with the gravity of the international situation, the Poles sent the English and French in 1939 an Enigma, as well as all of their discoveries.

    Bletchley park

    The English understood the interest of the Enigma machine quite late. In 1939, the service of the figure decides to move away from London, and the future bombardments, to settle, in all discretion, at the manor of Bletchley Park, in the peaceful countryside 60km north-west of London. Faced with the urgency of the situation, the best mathematicians, linguists, and even chess players are called to Bletchley Park, where several thousand people will meet.

    Among them, Alan Türing, a logician and mathematician, who, a few years earlier, designed a universal machine which formalizes the notion of algorithm and is the precursor of modern computers. He designed a new automatic machine, inspired by the Polish Bomb, to decipher German messages. The British also parachuted mines so that German submarines would mark the presence of its mines in their message. Thus, the presence of this probable word helped decipherment. Progress is then considerable. From the first to the second half of 1941, the tonnage sunk fell by half (from 2.9 million tonnes to 1.4 million).

    In February 1942, a new version of the Enigma machine was put into service, causing a new black hole in the decryption of messages. Thanks to documents recovered from a German submarine, and to the technical assistance of the United States, Bletchley Park found in mid 1943, still under the impetus of Türing, the faculty of deciphering German messages. In 1944, the first computer in history, the Colossus, guaranteed them sufficient computing power until the end of the war: the Battle of the Atlantic was won! This, especially since the Germans will never suspect that their messages are decrypted. They believe, rightly, that men cannot cope with such a titanic job. They have no idea that in Bletchley Park, in a mansion, a strange machine achieves this feat!

    Alan Turing’s work to decipher German messages profoundly changed the course of World War II. Several hundred ships, their crew and cargo, were saved. The landing of the summer of 1944 could be prepared in all serenity… Thanks to the genius of a mathematician!

    Enigma’s role in World War II

    If the First World War had been a war of positions (slow advances on battlefields facing each other), the Second World War will be done “on the move”. In 14-18, the communication of the armies was done by messengers on horseback and by carrier pigeons or by transmission of telegrams encrypted by hand, with a rather rudimentary coding. But from 1933, the German army changed its military strategy. It has acquired a significant strike force with more mobile armaments (tanks, armored vehicles, bombers, etc.). The effectiveness of this strategy then depends on the speed of the attacks on enemy positions, and on the coordination of the armies between them.

    This is how the Enigma machines, reinforced by German cryptologists for these new uses, will become an essential asset in securing military communications. Indeed, these machines multiply the strengths: they are fast, easier to use than other encryption methods thanks to their automatic electromechanical device. In addition, their small size allows them to be easily transported without hampering the mobility of the armed forces on which the new strategy of the German forces is based. There were some 30,000 at the start of the war and an estimated 200,000 by the end of the war.

    13,000 messages decoded between 1939 and 1942

    The machine was invented by Alexander Koch in 1919. He sold his patent to Arthur Scherbius who wanted to market it to protect companies from commercial and industrial espionage. Enigma was adopted by the Kriegsmarine in 1926 and then by the Wehrmacht in 1928. Thanks to the billions of possible combinations, the Germans had blind confidence in their machine. They only learned in the 1970s, and with amazement, that a large part of their secret messages had been decoded, which had enabled the allies to win, among other things, the Battle of the Atlantic and to beat the ‘Afrika Korps then was very useful during the landings in Provence and Normandy.

    It is thanks to Captain Gustave Bertrand, of the French intelligence services, to the documents provided by the German Hans-Thilo Schmidt and to the work of the Polish Biuro SzyfrÓw that the first messages were decoded in 1933. This work was then taken up by Alan Turing (to whom a film has been dedicated) in Bletchley Park at the start of the war.

    Sources: PinterPandai, Scientific AmericanBBCUniversity of St Andrews – ScotlandHarvard University

    Photo credit: ArnoldReinhold / Wikimedia Commons

    Photo explanations: Enigma Machine A16672 and another machine dug up from battlefield. Also one Enigma rotor and a Morse telegraph key. Items on display at the MIT (Massachusetts Institute of Technology) Flea Market.