"Magic" was the American umbrella name for intelligence from Japanese diplomatic messages that the US Army and Navy intercepted and decrypted before and during the Second World War. Its most famous component was the solution of the Japanese Foreign Office's top cipher machine, which American cryptanalysts called PURPLE. Strictly, Magic referred to the diplomatic material; the breaks into Japanese naval codes that set up the Battle of Midway were a separate effort, though the names are often blurred8.
A new machine in Tokyo
American codebreakers had been reading Japanese diplomatic traffic since the 1920s, including an earlier Foreign Office machine they called RED7. In the latter part of 1938 they intercepted messages arranging travel for a Japanese communications expert who was to install a new "Type B" cipher machine at major embassies. A message intercepted on 19 February 1939 gave the machine's start date as 20 February 19391. The Japanese designation was the 97-shiki obun injiki, roughly "Type 97 typewriter for European characters"6,7.
The Army's Signal Intelligence Service (SIS) in Washington attacked it. The new machine kept one weakness of RED: it split the alphabet into a group of six letters and a group of twenty, and the "sixes" were enciphered more simply. SIS recovered the sixes within months, but the twenties resisted all attempts1,7. William F. Friedman, the service's chief cryptanalyst, was assigned to supervise the effort in August 19391.
The September 1940 break
Friedman's own report, written on 14 October 1940 and later released through the National Archives, gives the clearest account of the solution. The team's key technique was to find "homologs," messages sent on different days with the same indicator that could be converted to a common base. This produced six messages in indicator 591731. On 20 September 1940, studying those messages, the team spotted repeated sequences. Friedman recorded the moment precisely:
This, on September 20, 1940, at about 2:00 P.M., was the very first indication that a successful attack might be possible.
By 27 September, the day Germany, Italy and Japan announced the Tripartite Pact, the team had handed in translations of the first two solved messages1. They also worked out that the machine used telephone-exchange stepping switches rather than rotors, and they built an equivalent from standard parts; Friedman credited Leo Rosen with the idea of using electrical telephone switches1. Friedman named the joint leaders as Frank Rowlett and Robert Ferner, and listed Genevieve Grotjan, Albert Small and Samuel Snyder among the junior cryptanalysts1. Later accounts single out Grotjan as the one who first saw the pattern7. Friedman himself insisted that "the name of no one person can be selected as deserving of the major portion of credit for this achievement"1.
No complete Japanese machine was ever captured. Fragments recovered from the Japanese embassy in Berlin in 1945 showed that the Americans had guessed the switching mechanism almost exactly7. Analog machines went to the Navy, to the Philippines and, in early 1941, to Britain, where they were traded for information on British work against German ciphers7. See Ultra and the breaking of Enigma.
How Magic was handled
Before Pearl Harbor the Army and the Navy's codebreaking unit, OP-20-G, split the decryption and translation of diplomatic traffic, the Army taking messages of even dates and the Navy odd ones2. Distribution was tiny: the Secretaries of War and the Navy, the Army Chief of Staff and the Chief of Naval Operations, the heads of war plans and intelligence in each service, the State Department, and the President through his naval aide2. Couriers generally showed the translations and took them back8. The congressional committee that investigated Pearl Harbor observed that the secret was guarded so closely that "the fact the Japanese codes had been broken was regarded as of more importance than the information obtained"3. It also recorded that the Army did not send Magic to field commanders, and that there was no record system showing who had seen which message2,3.
The Magic intelligence was preeminently important and the necessity for keeping it confidential cannot be overemphasized.
Pearl Harbor
Magic showed Washington that Japanese diplomats were working to deadlines, that Tokyo regarded the negotiations as all but finished after late November 1941, and, on 7 December, that the 14-part reply breaking off talks was to be handed to Secretary of State Cordell Hull at 1 p.m. Washington time2,6. Intercepts also included Tokyo's instruction of 24 September 1941 telling the Honolulu consulate to report ships in Pearl Harbor by sub-area, which critics later called the "bomb plot" message2. General George Marshall's warning on the morning of 7 December went by commercial telegraph rather than by telephone2.
The war and after
Through the war Magic's richest vein was the reporting of General Hiroshi Ōshima, Japan's ambassador in Berlin, whose long PURPLE dispatches described conversations with Hitler and German defenses in France7,8. In September 1944 Marshall wrote privately to the Republican candidate Thomas Dewey to keep the codebreaking out of the presidential campaign8; the committee cited those letters for "a discussion of Magic and its great significance"2. The committee also urged Congress to look at the law on leaks, noting that wartime violations involving Magic could not be prosecuted without giving the secret to the enemy3.
The congressional hearings of 1945–1946 made Magic public. In 1977 the Department of Defense released a multi-volume collection of the 1941 intercepts, The "Magic" Background of Pearl Harbor5. The work of SIS and OP-20-G passed after the war to the agencies that became the National Security Agency (NSA). For how the British and Americans protected similar material against Germany, see Ultra and the breaking of Enigma and Signals intelligence.
The documents
Declassified records of this operation, with the scans and their full text hosted here.
Checking the record
Dates and outcome compared in two independent sources: they agree.
- National Archives
- Type B machine in effect from 20 February 1939; first indication of a solution on 20 September 1940; first two messages solved by 27 September 1940. Machine's principles reconstructed and an equivalent machine built; by mid-October 1940 over a third of the 120 indicators solved.
- Wikipedia
- Type B messages began to appear in February 1939; breakthrough in September 1940; two messages decrypted by 27 September 1940. SIS built an analog machine without seeing the original; Purple traffic was read through the war and the Japanese never believed it broken.
Dates and outcome agree. Wikipedia credits the September 1940 breakthrough specifically to Genevieve Grotjan; Friedman's contemporary report lists her among the team but describes the result as collective, and this page follows both by naming her without assigning sole credit.
Sources
- National Archives Preliminary Historical Report on the Solution of the "B" Machine (William F. Friedman, 14 October 1940), US Army Signal Intelligence Service; NARA (scan via cryptocellar, archived) (1940-10-14).
- Congress Investigation of the Pearl Harbor Attack: Report of the Joint Committee, Part IV, Responsibilities in Washington (S. Doc. 244, 79th Congress), US Congress (transcription at ibiblio.org) (1946-07-20).
- Congress Investigation of the Pearl Harbor Attack: Recommendations (Part V), US Congress (transcription at ibiblio.org) (1946-07-20).
- Congress Investigation of the Pearl Harbor Attack: Minority Views of Mr. Ferguson and Mr. Brewster, US Congress (transcription at ibiblio.org) (1946-07-20).
- Other The "Magic" Background of Pearl Harbor (index and Department of Defense foreword), US Department of Defense (transcription at ibiblio.org) (1977).
- Other PURPLE Revealed: Simulation and Computer-aided Cryptanalysis of Angooki Taipu B, Wes Freeman, Geoff Sullivan and Frode Weierud, Cryptologia (2003).
- Wikipedia Type B Cipher Machine, Wikipedia.
- Wikipedia Magic (cryptography), Wikipedia.
- Wikipedia English Wikipedia article (used for cross-checking).
Elsewhere in the files
- Agency GC&CS and GCHQ
- Agency Office of Strategic Services (OSS)
- Document Friedman's report on breaking PURPLE (14 October 1940)
- Document The BRUSA agreement on 'Special Intelligence' (1943), with the War Department's covering memo
- Operation Ultra and the breaking of Enigma
- Person Alan Turing
- Tradecraft Cipher machines
- Tradecraft Signals intelligence
