Programming Colossus (Cracking Enigma)

I forgot to include the link where you can see a facsimile of a code book and an explanation of how it was used. The first column is the day of the month. The second column is the rotor order. The third column is the ring settings. The fourth column is the plugboard settings. There is a fifth column called Kenngruppe which was not necessarily used as that page explains.

In this page you can also see an example of how the Enigma was used in practice.

My understanding is that Colossus wasn’t pure brute force but was set to start with likely combinations based on cribs, link chains (which was the first undoing of the Enigma - I think we have those two Polish mathematicians to thank for that one), and other intelligence.

I have to second “The Code Book” by Simon Singh. That’s the best non-fiction read I’ve had in years.

For those of you still interested in Colossus:

The documents are at:

These days only a few original Enigmas exist and they change hands for £150,000-£250,000. Mick Jagger is a famous owner and lent his to the makers of ‘Enigma’ and got a thanks in the credits.

After the war there were hundreds if not thousands of the things available cheap through army surplus stores and scrap merchants.

There is a conspiracy that the British Government encouraged various countries to buy up and use these, without mentioning that they knew how to crack them. But there’s little evidence to prove that. The more likely truth is that governments just bought them cheap. Some of them were still in use up until the 80’s.

An actual photo of Collusus

Ms Mortimer does not have fond memories of her time working with Colossus.

“We worked terribly long hours in not terribly pleasant working surroundings,” she said. “We stood up all the time to operate the machine, so it was terribly tiring.”

Enigma was nothing like modern-day asymmetric encryption of the PGP sort. Asymmetric encryption (where you’d use different keys to encrypt and decrypt, and can consequently safely publish the one for encryption) was only developed in the 1970s.

It’s a rule of best practice in cryptography that the security of the scheme should rely on the secrecy of the key, not that of the algorithm. The Wehrmacht could not communicate keys in plain text and rely on the enemy not having a physical Enigma as the only safeguard, as your public/private key analogy implies.

(In fact, the Enigma was a commercially marketed product in the 1920s, available for anyone to buy. They were also patented, so anybody could look up the mechanics of the device. The Wehrmacht used a modified version rather than the civilian editions, but it goes to show that you can’t rely simply on the secrecy of the machine itself to provide secure encryption.)

And she probably got paid about a tenth of what a man would have gotten for the same work.

This guy offers functioning replica Enigmas for sale. There’s no price posted, so I suppose he makes them himself when someone places an order, and they’re expensive; but elsewhere on his website he says he is also trading in original working Enigmas, with prices ranging between $250k and $400k, so I guess the replica option will still be significantly cheaper.

One very important fact is required here!
Colossus was NOT designed to break Enigma, the Bombe machines did that.
Colossus was used on the very high-level Lorentz teleprinter cipher that the High command used.

Hello. Did the OP’s question from 20 years ago ever get answered?

I’m not at all programming savvy, but it seems that the only response that addressed the OP’s question was #10, which received no replies or elaborations, and is too technical for me to understand.

So, the bombe had a target result, and each automated attempt to discover the Enigma’s starting position produced a score of some sort? Is that roughly accurate? Could anyone simplify or elaborate?

They were WRENS. ( The Women’s Royal Naval Service was the women’s branch of the Royal Navy. First formed in 1917 for the First World War,)

As far as I can tell, they were paid at about half the rate of a similarly ranked male sailor.

It’s the Lorenz, and Colossus (not Bombe and Enigma), but it sounds like it was pretty automated.

Basically the entire cipher stream is evaluated and a series of XOR operations is performed to determine how often the XOR of subsequent characters in the Cipher text matched the XOR of subsequent Chi-wheel output characters (this was done for each possible Chi-wheel input). If the Chi wheel settings were right these operations would match 55% of the time. If they were wrong it would be 50%. This is due to the non-random frequencies of letters in German.

The computer was built to do these operations very quickly and cumulate a sort of “running total”. The right Chi-wheel settings would produce an obviously different result than the wrong ones.

Some math and an explanation of the attack can be found here: The Double Delta Attack

From here: The Colossus Machine

Any possibly correct wheel settings (ones that produced a higher-than-expected number of matching zeros) would be printed out automatically.

ETA: One subtlety I glossed over is that there are 5-bits for each character and only the first two bits are exactly compared (hence the discussion of 2 of the 5 tracks).

Thank you muchly. I’m googling some terms and reading the Stanford link — and learning a small, enjoyable, bit.

yes.

Its loose talk to say to that the germans “transmitted the rotor settings each night”. I think they were referring to way regular check ins and things like weather reports would be of the same form, and they could see the same patterns in the cipher text… and that assisted the code breakers to get derive the new keys. So that early hours would be “key retrieval” time…

There is a book that came out a few years after this thread was started called “Colossus: Bletchley Park’s Greatest Secret” by Paul Gannon. It’s been years since I read it but scanning the TOC makes it look like it should answer the OP’s question.