IT lexicon Security Substitution cipher

Substitution cipher

Security På svenska → Updated: 2026-08-03

Swap each character for another according to a fixed table — and awkwardly preserve the entire statistics of the language.

Every character in the plaintext is replaced by another according to a fixed mapping. A monoalphabetic cipher uses the same table throughout; a polyalphabetic one, such as Vigenère, switches tables along the way. The key space for an arbitrary permutation of 26 letters is 26 factorial, roughly 4·10²⁶, which sounds reassuring.

It is not. Because every plaintext letter always maps to the same ciphertext letter, the language's frequency distribution survives completely intact, and a few hundred characters of text can be broken with pen and paper. Al-Kindi described the attack as early as the ninth century. Modern cryptography uses substitution as a component — that is what an S-box is — but never on its own.

← Back to the lexicon