Known Plaintext Attack

A known plaintext attack can be devastating. If one knows, or can guess, part of the plaintext of an enciphered message then this can be used as a 'wedge' into the message.

The question arises about how we can know part of a plaintext for an enciphered message which we need to break? It sounds like a chronic case if 'the chicken and the egg'.

Quite simply, really. In World War 2, the cryptologists used a technique known as 'gardening'. When the germans cleared a minefield using minesweepers, there would be radio traffic mentioning 'mines' and the 'coordinates'. On occasion, the cryptographers would request that a particular area be mined in order to generate messages with some known plaintext, some directing the area to be cleared, others reporting job done. They would 'plant the seeds' from which the messages with known plaintext would 'grow'.

The U boats would also transmit weather reports when they surfaced mid atlantic, if allied shipping were nearby, they would also know the local weather, and the cryptographers would be able to correlate this information.

Even without this information, some plaintext could be guessed, German radio operators often signed off with 'HH' (Heil Hitler), there would often be addressing information too - so if the source of the transmission were known by direction finding, intelligent guesses could be made.

A known plaintext is incredibly valuable. Suppose that we have the following message which is encrypted in the 'Beaufort' cipher. We have good reason to believe that the word 'firefly' is part of the plaintext.

CT: FSHHZTMSGXRAWVMNZEPMEUWLGIRXIN

We would slide the word 'firefly' along the message, working out what the key would have been. Then assuming that we could work out other parts of the message with the assumed key (or partial key) as a basis and see if other words appear. As might be imagined, this can be quite time consuming, but it might be a quicker way in that conventional cryptanalysis.

In our case, the first position yield the key 'Kaylee', and we are lucky that repeating this key over the whole message reveals text immediately - the known plaintext was enough to recover the entire plaintext!

CT: FSHHZTMSGXRAWVMNZEPMEUWLGIRXIN
KY: KAYLEEKAYLEEKAYLEEKAYLEEKAYLEE
PT: FIREFLYISONEOFMYFAVOURITESHOWS

Reformatting: "Firefly is one of my favourite shows" - roll on Serenity!