Ancient Cryptography: The Caesar Cipher
The Caesar cipher is perhaps one of the most well known forms of ancient cryptography. Which is why it probably should have been the focus of the first article in this series, but at least we’re here now right? So... what exactly is it? Well, it’s the cipher that Caesar allegedly employed to encode his military communications. Even back in Roman times, the importance cryptography in keeping military movements secret would not have been lost on an influencial emperor like Caesar. It’s also interesting in that it’s just about the simplest cipher in existence.
But how does it work?
The Caesar cipher falls under the category of substitution ciphers, which includes any method of encryption where one letter/symbol is replaced by another. In the case of the Caesar cipher, each letter is replaced by a corresponding letter a certain number of positions down the alphabet. This positional shift would then be your cryptographic “key” that you would need to decode an encrypted message. So, for instance, if you decided to shift all letters by one, then “a” would be represented by “b” and “b” would be “c” and so on. The person who received your message just shifts every letter back one, in the opposite direction. For military correspondence Caesar opted for a shift of three. This worked for him back then, but this system has obvious flaws.
Breaking the cipher
This is definitely not a strong cipher. For example, someone could easily intercept your gibberish message, and then tell that it was a Caesar cipher. It would then be trivial to simply rewrite the message with all 26 possible positional shifts, until it became clear. With the advent of computers this process takes a fraction of a second, so this cipher has no real use anymore, besides maybe passing notes in class.
The modern Caesar cipher
That is, except for a subset of the Caesar cipher, called “ROT13”. Because of its unique properties ROT13 stuck around until the early 2000s. ROT13 is literally just a Caesar cipher with a shift of 13. This seems unremarkable, until you consider the fact that 13 is exactly half of the 26 letter alphabet. This means that a message can be encoded using rot-13 by shifting its letters by 13, and then decoded through the same shift of thirteen. This means that the same algorithm (or program) can be used both to encode and decode a message when using ROT13. This made it perfect for an unlikely purpose. Many online quizzes in the early days of the internet encoded answers in ROT13. This way, when you wanted to check your answers you’d simply decode the answer sheet using the ROT13 algorithm (a program to do this is included on most Linux distros) and compare. It’s kind of amazing that a cipher invented back in Roman times would still be used today.
If you want to play around with ROT13 check out this website.
Even though this concept is probably pretty familiar, I hope you found this article interesting!