Polygraphic substitution ciphers

Description

Algorithm

Implementation

Polygraphic substitution divide the plaintext into groups of letters. Then, they replace each group of letters by one of the predefined letters, numbers, graphic symbols, or by another group of characters.

Polygraphic substitution ciphers

Polygraphic substitution ciphers were invented during the Renaissance as an improvement of simple substitution ciphers. There were used by diplomats in Europe for many centuries.

Polygraphic substitution ciphers work by dividing the plaintext into many parts, and replacing each group by a word, a single character or number, or anything else. To decrypt ciphertext letters, one should use the reversed substitution and change phrases in the opposite direction.

The main motivation of introducing ciphers of this type was a possibility to obscure frequencies of ciphertext characters. To achieve that, popular plaintext phrases should be replaced by one of a few previously assigned to that phrase characters, numbers, or other phrases. Different replacements should be used randomly, thus making the frequency analysis much more difficult.

Polygraphic substitution ciphers provide larger randomness and flexibility that homophonic substitution ciphers due to a possibility to encrypt whole groups of characters at once.

A popular technique used in polygraphic substitution ciphers is to assign several predefined words or numbers to each popular plaintext word. European diplomats used codenames to encode important institutions, places, and names of important people.