How a sarcastic phrase nearly lost a naval battle
In short: In the world of cryptography, padding is the art of adding extra data to hide patterns. But in 1944, a misunderstood piece of padding—intended as nonsense filler—was mistaken for a biting insult by an Admiral, nearly causing a catastrophic military blunder during World War II.
Padding serves several roles depending on the era of cryptography. In classical systems, it was used to obscure predictable linguistic patterns, such as standard sign-offs like "Sincerely yours." By adding nonsense phrases or random lengths, cryptanalysts were prevented from identifying known plaintexts that could break an encryption. However, because these fillers were often human-readable, they could be misinterpreted by the recipient.
A primary example of this occurred on October 25, 1944, during the Battle of Leyte Gulf. Admiral Chester Nimitz sent a message to Admiral William Halsey asking for the location of Task Force Thirty Four. To obscure the message's structure, he used padding that included the phrase "THE WORLD WONDERS." Because the radio operator failed to signal that this was filler (using the standard "RR" indicator), Halsey’s team read it as a sarcastic reprimand. This caused Halsey to sulk for an hour before moving his forces, nearly resulting in an Allied loss at the Battle off Samar.
Modern cryptography has largely moved away from these types of linguistic fillers because contemporary ciphers are secure even if an attacker chooses the message content. Today, padding is primarily a structural necessity. Block cipher modes like Cipher-block chaining (CBC) require input to be a multiple of a specific block size; padding fills those remaining gaps. For example, PKCS#7 might add bytes where each byte's value equals the total number of bytes added. While necessary for structure, these patterns can introduce vulnerabilities like "padding oracle attacks," which modern systems mitigate using Message Authentication Codes (MACs) or by switching to streaming modes that require no padding at all.
Hash functions also rely on padding to process messages in fixed-length blocks. Schemes like those used in MD5 and SHA-1 include specific termination rules to prevent "length extension attacks." These mechanisms ensure that the mathematical integrity of the hash remains intact regardless of the input message's original size.
Opens the Intellect+ feed with this card first. Swipe up for the next one.
Sources
- Summary by Intellect · source: Padding (cryptography)
To cite this card, link to https://intellectplus.co.uk/app/technology-padding-cryptography.
How we source, check and correct cards: Editorial standards.
General information, not professional advice. Spotted an error? Flag the card or see corrections and complaints.
Intellect Plus is a visual educational discovery platform for exploring fascinating facts and ideas. Brain Food, Not Brain Rot. What is Intellect Plus?
Related
More in Cryptography · More in Technology · Latest · A–Z · All topics