Friday, January 21, 2011

Colossus

Colossus Mark II had 2,400 valves

I just finished reading this book about WWII codebreaking at the legendary Bletchley Park site in England. The cracking of the Enigma codes is well known, but BP also worked on another Nazi cipher system that the Brits code-named "Fish". This was a family of encrypted teletype machines using 5-bit baudot code (32 characters, or, actually, 31 characters and one "null" symbol).

The Enigma machines used three or four 26-contact wired wheels to scramble the text. The Fish machines used 12 wheels, all of different sizes, all of which were co-prime (i.e. not sharing any factors) to produce an enormously long pseudo-random key sequence. This 5-bit key, added to the 5-bit plaintext in the "exclusive-or" (XOR) manner, produced the ciphertext. To decipher, the recipient just added the key to the ciphertext in the XOR manner to reproduce the plaintext. All of this was done automatically, using punched paper tape. The Fish machines could be hooked up to landlines or connected to a radio transmitter, and the latter is how BP came to intercept them.

The Brits cleverly deduced how the machine was designed without ever having seen one and devised ingenious paper-and-pencil methods to break the code and read the plaintext. The Nazis changed the key every day at midnight, and the BP nightshift would desperately try to extract the key. Once the key was known, any intercept that day could be decoded using the "Fish" analogue machines built at BP. Most of the cryptanalysts at BP rarely saw a decrypted message; they didn't have to. They were interested in extracting the key.

But as the war progressed, the Nazis continually upgraded the security on the "Fish" until BP's paper-and-pencil solutions were taking several days, then several weeks to complete. This was costing Allied lives, so automated methods were devised, the first being "Heath Robinson" devices (we would call them "Rube Goldberg" machines). These were high-speed paper tape readers that could run two message tapes synchronously at about 30-mph and compare them for statistical anomalies. This put BP back in the business of reading the messages on a daily basis, for a while.

Better operator security eventually outran the Heath Robinsons, and an all-electronic method was suggested by Thomas Flowers, on loan to BP from the British telephone system, where he had designed and installed the first all-electronic telephone switching system in Britain. Flowers designed the first Colossus computer, a 1500-tube (the Brits call them "valves") behemoth, to search for statistical anomalies a thousand times faster than the Heath Robinsons. The "Colossi" were built on an emergency basis, 'round the clock, the men literally sleeping in the shop when they weren't working. There were eventually eleven Colossus machines. Flowers was already designing improvements into the next unit before its predecessor was out the door. The last Colossus was delivered to BP just as the war was ending.

The most interesting thing I gathered from the book is that the legendary mathematician Alan Turing was not involved in the design or operation of the Colossus at all. He worked on Enigma codes only.

This color photo is of a modern replica of a WWII Colossus at Bletchley Park, all of the originals having been destroyed at the end of the war (Churchill is said to have specifically ordered that they be broken down into "pieces no bigger than a man's hand"). Although there are rumors that one or two may have survived at GCHQ or NSA, and used for training. After the war, captured Fish machines were used by the French and also by the East German "Stasi", which considered them unbreakable. They were phased out in the 1960s.

The level of secrecy imposed by the British Official Secrets Act makes the American NSA look like a relative blabbermouth: details of the Colossus were not declassified by the Brits until October 2000. At the end of the war, the British cryptographers wrote a secret report on their work, knowing that it would not be released during their lifetimes. It included this rather poignant description of the Colossus:

It is regretted that it is not possible to give an adequate idea of the fascination of a Colossus at work; its sheer bulk and apparent complexity; the fantastic speed of thin paper tape round the glittering pulleys; the childish pleasure of not-not, span, print main header and other gadgets; the wizardry of purely mechanical decoding letter by letter (one novice thought she was being hoaxed); the uncanny action of the typewriter in printing the correct scores without and beyond human aid; the stepping of the display; periods of eager expectation culminating in the sudden appearance of the longed-for score; and the strange rhythms characterizing every type of run: the stately break-in, the erratic short run, the regularity of wheel-breaking, the stolid rectangle interrupted by the wild leaps of the carriage-return, the frantic chatter of a motor run, even the ludicrous frenzy of hosts of bogus scores.

About Me

And You Can Quote Me!

"If you've got to resist, your chances of being hurt are less the more lethal your weapon. If that were my wife, would I want her to have a .38 Special in her hand? Yeah." - Dr. Arthur Kellermann, Health Magazine (March/April 1994) p 61