Bellaso cipher
known as the Vigenère cipher
The countersign picks the alphabet for each letter, so the same letter is encrypted one way, then another — until the countersign repeats.
- Made
- 1553, Venice — Giovan Battista Bellaso of Brescia
- Broken
- 1863, Berlin — Friedrich W. Kasiski publishes a method to break it
- How it works
- each letter of the countersign picks one of 11 alphabets; the plaintext letter swaps with the letter above or below it
- Today
- AES-GCM and authenticated encryption, ChaCha20-Poly1305
- Sources
- P. Bonavoglia, Trithemius, Bellaso, Vigenère. Origins of the Polyalphabetic Ciphers, HistoCrypt 2020, pp. 46–51
- G. B. Bellaso, La cifra del Sig. Giovan Battista Belaso, Venice 1553 (photograph of the table, Wikimedia Commons)
- Wikipedia EN, Giovan Battista Bellaso (the example with the countersign VIRTVTI OMNIA PARENT)
- F. W. Kasiski, Die Geheimschriften und die Dechiffrir-Kunst, Berlin 1863, § 89–91 (scan, Google Books)
- The Index of Coincidence and Its Applications in Cryptography, Riverbank Publication No. 22, Paris 1922 (scan, Marshall Foundation)
- P. Norvig, English Letter Frequency Counts (control table)
The table of 1553
The Bellaso cipher encrypts each letter with one of 11 alphabets. A letter of the countersign picks it (Bellaso wrote contrassegno, English countersign); the countersign is written over the text and repeated when it runs out. So the same plaintext letter can give different ciphertext letters, depending on which countersign letter stands over it.
Each alphabet has two rows: the upper one holds 11 letters from A to M, the lower one the other 11, moved by a different number of places in each alphabet. A letter of the text swaps with the letter in the same column of the other row, whichever row it stands in. One alphabet serves two countersign letters (AB, CD, … YZ), hence 11 alphabets for 22 letters.
The operation is reciprocal: the same table with the same countersign encrypts and decrypts, and a letter always swaps with a different one. The button “Decrypt with the same countersign” moves the ciphertext into the text field and shows it.
The replica keeps to the original: it has 22 letters, without J, K and W. You write J as I and U as V; K and W have no counterpart, so the replica leaves them out and says so under the field. The first text and countersign are the example attributed to the 1553 booklet (its place in the original is not established). The replica gives SYBOV EYLDA NVOFS ZLPII NCVPN SHMLR NXOIZ NRD for it, 38 letters out of 38.
Table of 1553
The countersign repeats over the text when it runs out.
The 1553 alphabet has 22 letters: J is I, U is V. Polish letters lose their marks.
Letter 1 of 38: L, countersign V, alphabet VX — L swaps with S.
The length of the countersign from the gaps between repeats
The countersign repeats every few letters. When the same stretch of plaintext lands under the same part of the countersign, the ciphertext repeats with it. The gap between such repeats is a multiple of the countersign’s length. Friedrich W. Kasiski published this method in 1863.
You break a later form of this cipher: a 26 × 26 square, in which a countersign letter shifts a text letter as in the Caesar cipher. That is the cipher known today as the Vigenère cipher. Kasiski’s method works on Bellaso’s table too, because both ciphers repeat the countersign. The difference is in the columns: in the square each column is a separate Caesar cipher, in Bellaso’s table a separate reciprocal substitution.
You do it in four steps. The first looks for repeats: stretches of at least three letters that occur in the ciphertext twice or more. The second chooses the length of the countersign. For lengths from 2 to 8 the page counts how many gaps divide by it without a remainder. The rule is: take the largest length that divides at least 60% of the gaps. The divisors of the real length divide the same gaps as it does, which is why you take the largest. An optional button also computes the index of coincidence. That method is from the 20th century: Riverbank Laboratories’ Publication No. 22 described it in 1922.
The third step is the columns. You write the ciphertext in as many columns as the countersign has letters. Each column is encrypted with one countersign letter, so it is one Caesar cipher: move the countersign letter with the slider until the column’s bars cover the outline of the language’s letter frequencies (as in the Caesar and substitution exhibits). With a wrong length the columns mix several alphabets and no shift fits them. The fourth step is the verdict: broken when the text you read back matches the original.
The passage has 300–400 letters and comes from a public-domain novel, and the countersign is a word of 3–6 letters. The page draws a pair again until the method has a chance: a column must have at least 50 letters, at least three repeats must have a gap that is a multiple of the countersign’s length, and the rule of the second step must name the right length. On this page’s corpus about 9 pairs in 10 pass, and at 50 letters in a column the best fit finds the right countersign letter in at least 99% of columns.
Kasiski’s method
Ciphertext intercepted. Look for repeats in it: their gaps give away the length of the countersign.
Look for repeats
simplificationYou break a later form of this cipher — a 26 × 26 square, known today as the Vigenère cipher. Kasiski’s method works on Bellaso’s table too, because both ciphers repeat the countersign.
The same run of letters in the ciphertext usually means the same stretch of text under the same stretch of the countersign.
What we know about Bellaso and the name “Vigenère”
Johannes Trithemius published in 1518 (written in 1506–1508) a table of 24 alphabets shifted by successive places. He encrypted the first letter with the first alphabet, the second with the second, and so on, with no countersign (Bonavoglia 2020, p. 46).
The countersign was introduced by Giovan Battista Bellaso in 1553. He was the first to choose alphabets by an agreed countersign:
The second well known polyalphabetic cipher is the one of G.B. Bellaso published in Venice in 1553, which for the first time introduces what today is called a password or pass-phrase as the key.
His table has 11 reciprocal alphabets, named by the pairs AB, CD, … YZ, on a 22-letter alphabet without J, K and W, with U written as V (Bonavoglia 2020, pp. 47–48; photograph of the table). For centuries it was called “Porta’s table”, an example of the mistakes that come from relying on second-hand sources (Bonavoglia 2020, p. 48).
Blaise de Vigenère showed this table in 1586, reduced to 20 letters, and credited it to “a certain Belasio”. In the same treatise he turned it into a Trithemius-like square with a keyword, simpler to use than Bellaso’s table (Bonavoglia 2020, pp. 48–49). Today’s “Vigenère cipher” is something other than the table of 1553:
The classic Vigenère table is a Trithemius like cipher, using a Bellaso's like keyword.
Friedrich W. Kasiski published a general method for breaking ciphers with a repeating key in Berlin in 1863. His recipe: find the repeats in the ciphertext, count the distances between them and break those numbers into factors. The most frequent factor is the length of the key (Kasiski 1863, § 89–91).
The same pattern today
A short countersign repeats every few letters. The gaps between repeats give away its length, and every column is a separate substitution.
The same nonce under the same key repeats the key stream. In AES-GCM two such messages reveal the XOR of their plaintexts and let an attacker forge the tag.
See it in the station: AES-GCM and authenticated encryption →