Monoalphabetic
Also known as : Simple substitution
A cipher is called monoalphabetic when it uses a single substitution table for the entire message: each plaintext letter is mapped to one ciphertext letter, always the same. If A → D at the start of the message, then A → D at the end too. No evolution over time. It’s the oldest and simplest family, and also the most pedagogical for understanding how a cipher works — and how it falls.
Canonical examples
- Caesar (50 BCE): fixed alphabet shift. Key is an integer between 1 and 25. The shift-3 (Julius’s version) gives A→D, B→E, C→F… Key space: 25.
- ROT13 (Internet, 1980s): Caesar of 13. Special property: it’s its own inverse (ROT13 twice yields the plaintext). Heavily used on Usenet to hide spoilers and corny jokes.
- Atbash (Hebrew alphabet, ~600 BCE): alphabet mirror. A↔Z, B↔Y, C↔X… No key: it’s a single deterministic transformation. Appears in biblical texts (the word “Sheshach” in Jeremiah 25:26 = “Babel” in Atbash).
- General monoalphabetic substitution: the table is an arbitrary permutation of the 26 letters. The key is that permutation. Key space: 26! ≈ 4 × 10²⁶ — astronomical in theory, yet general substitution falls in minutes to frequency analysis.
- Affine:
c = a × p + b mod 26. Combines shift (b) and multiplication (a). 12 valid values fora× 26 forb= 312 keys. More subtle than Caesar, still monoalphabetic.
The golden rule of monoalphabetic ciphers
All these ciphers share one fundamental weakness: they preserve letter frequencies. If E is 12.7 % of plaintext, the letter replacing it is exactly 12.7 % of ciphertext. Cryptanalysis just has to count, sort, and match.
This weakness isn’t designer carelessness; it’s a mathematical consequence of the architecture. A fixed table cannot make a frequent letter “disappear” — it just moves it. To break that rule, you must either swap tables along the way (polyalphabetic ciphers) or encipher by groups instead of letter-by-letter (polygraphic ciphers).
Cryptanalysis walkthrough
Take the ciphertext (English, general monoalphabetic substitution):
WK XIIW MV WKZJ WD VKWAB G XV B BWAK GZ CFKZ - Counting: list frequencies.
Wshows up 6 times,K5 times,Z3 times. - Frequency hypothesis: the most frequent letter is probably E. So
W = E. - Short words: spot single letters → likely
AorI. We seeGalone, thenBalone — tryG = I,B = A. - Common digrams:
KZ→ maybeEN,RE,ON. We sawKis high, so tryK = T(THE pattern). - Common word:
WKZ(three letters with no apostrophe) → likelyTHE. WithW = E? No, that’sXHE. TryW = T, K = H, Z = E. Recheck —THEeverywhere coherent.
We iterate. On a longer text (200+ characters), about ten iterations suffice. On isolated short words you sometimes get stuck. The whole beauty of manual cryptanalysis is in this dance between counting and hypotheses.
Index of coincidence as a signature
The index of coincidence of a monoalphabetic ciphertext stays the same as the plaintext (≈ 0.067 in English, 0.074 in French). It’s a recognizable signature at first glance for a cryptanalyst: faced with an unknown ciphertext whose IC sits at ~0.067, you know you’re in monoalphabetic territory before you’ve tested any key. Conversely, a ciphertext with IC ~0.04 is probably polyalphabetic.
Stepping up the security
If monoalphabetic isn’t enough:
- Polyalphabetic (Vigenère, Beaufort, Autokey, Enigma): you switch substitution tables based on position. Flattens frequency. The key becomes a word, a phrase, or even a long random sequence. Crackable by Kasiski + IC, but vastly more resistant.
- Polygraphic (Playfair, Hill): you encipher groups of letters (pairs, triples) rather than single letters. Preserves frequencies at the n-gram level — harder to attack.
- Homophonic: you assign multiple ciphertext symbols to each frequent plaintext letter, picked at random. Also flattens frequency. The Beale ciphers (19th century) are an example.
None of these are mathematically unbreakable — you have to switch to AES or the one-time pad for that. But they raise the bar enough for serious pedagogical or recreational use.
Key takeaways:
- Monoalphabetic = one substitution table for the entire message. Oldest, simplest family.
- Includes Caesar, ROT13, Atbash, general substitution, Affine.
- Preserves letter frequency → crackable by frequency analysis in minutes.
- Index of coincidence unchanged from plaintext (~0.074 FR, 0.067 EN). Recognizable signature.
- To improve security: move to polyalphabetic (Vigenère), polygraphic (Playfair), or modern (AES).