Cryptanalysis
ADFGVX was cryptanalysed by French Army Lieutenant Georges Painvin and the cipher was broken in early June 1918. The work was exceptionally difficult by the standards of classical cryptography, and Painvin became physically ill during it. His method of solution relied on finding messages with stereotyped beginnings, which would fractionate the same, then form similar patterns in the positions in the ciphertext that had corresponded to column headings in the transposition table. (Considerable statistical analysis was required after this step had been reached — all done by hand.) This meant it was only effective during times of very high traffic — but, fortunately for the cryptanalysts, that was also when the most important messages were sent.
However, that was not the only trick Painvin used to crack the ADFGX cipher. He used repeating sections of ciphertext to derive information about the likely length of the key being used. Where the key was an even number of letters in length he knew, due to the way the message was enciphered, that each column consisted entirely of either letter coordinates taken from the top of the Polybius Square, or from the left of the Square, but not a mixture of the two. He also knew that after substitution, but before transposition, the columns would alternately consist entirely of "top" and "side" letters. One of the characteristics of frequency analysis of letters is that while the distributions of individual letters may vary widely from the norm, the law of averages dictates that groups of letters vary less. With the ADFGX cipher, each "side" letter or "top" letter is associated with five plaintext letters. In the example above, the "side" letter "D" is associated with the plaintext letters "d h o z k", while the "top" letter "D" is associated with the plaintext letters "t h f j r". Since these two groups of five letters have different cumulative frequency distributions, then a frequency analysis of the "D" letter in columns consisting of "side" letters will have a distinctively different result from those of the "D" letter in columns consisting of "top" letters. This trick allowed Painvin to tentatively identify which columns consisted of "side" letters and which columns consisted of "top" letters. He could then pair them up and perform a frequency analysis on the pairings to see if they were noise, or real pairings that corresponded to plaintext letters. Once he had the proper pairings, he could then use frequency analysis to figure out the actual plaintext letters. The result was still transposed, but at that point all he had to do was unscramble a simple transposition. Once he determined the transposition scheme for one message, he would then be able to crack any other message enciphered with the same transposition key.
Painvin broke the ADFGX cipher in April 1918, a few weeks after the Germans launched their Spring Offensive. As a direct result, the French army discovered where Ludendorff intended to attack. The French concentrated their forces at that point and it has been claimed that this stopped the Spring Offensive.
Note, however the claim that Painvin's breaking of the ADFGX cipher stopped the German Spring Offensive of 1918, while frequently made, is disputed by some. In his 2002 review of Sophie de Lastours' book on this subject, La France gagne la guerre des codes secrets 1914-1918, in the Journal of Intelligence History, (Journal of Intelligence History: volume 2, Number 2, Winter 2002) Hilmar-Detlef Brückner states:
Regrettably, Sophie de Lastours subscribes to the traditional French view that the solving of a German ADFGVX-telegram by Painvin at the beginning of June 1918 was decisive for the Allied victory in the First World War because it gave timely warning of a forthcoming German offensive meant to reach Paris and to inflict a critical defeat on the Allies. However, it has been known for many years, that the German Gneisenau attack of 11 June was staged to induce the French High Command to rush in reserves from the area up north, where the Germans intended to attack later on. To achieve this, its aim had to be grossly exaggerated. This the German High Command did by spreading rumors that the attack was heading for Paris and beyond; disinformation proved effective then - and apparently still does. But the German offensive was not successful because the French had a sufficient number of reserves at hand to stop the assault and did not need to bring in additional reinforcements. Moreover, it is usually overlooked that the basic version of the ADFGVX cipher had been particularly created for the German spring offensive in 1918, meant to deal the Allies a devastating blow. It was hoped that the cipher ADFGX would protect German communications against Allied cryptographers during the assault and this is what it indeed did. Telegrams in ADFGX appeared for the first time on 5 March, the German attack started on 21 March. When Painvin presented his first solution of the code on 5 April, the German offensive had already petered out.
The ADFGX and ADFGVX ciphers are now regarded as insecure.
Read more about this topic: ADFGVX Cipher