Vigenère Cipher

Key

The Vigenère Cipher is a method of encrypting alphabetic text where each letter of the plaintext is encoded with a different Caesar Cipher, whose increment is determined by the corresponding letter of another text, the key. [Wikipedia]


The Vigenère Cipher is a polyalphabetic substitution cipher. The method was originally described by Giovan Battista Bellaso in his 1553 book La cifra del. Sig. Giovan Battista Bellaso; however, the scheme was later misattributed to Blaise de Vigenère in the 19th century, and is now widely known as the Vigenère Cipher.


Blaise de Vigenère actually invented the stronger Autokey Cipher in 1586.


First described by Giovan Battista Bellaso in 1553, the cipher is easy to understand and implement, but it resisted all attempts to break it until 1863, three centuries later. This earned it the description le chiffrage indéchiffrable (French for 'the indecipherable cipher'). Many people have tried to implement encryption schemes that are essentially Vigenère ciphers. In 1863, Friedrich Kasiski was the first to publish a general method of deciphering Vigenère ciphers. Charles Babbage had, however, already developed the same test in 1854. Gilbert Vernam worked on the vigenere cipher in the early 1900s, and his work eventually led to the one-time pad, which is a provably unbreakable cipher.


In the 19th century, the scheme was misattributed to Blaise de Vigenère (1523–1596) and so acquired its present name.


The Vigenère cipher is therefore a special case of a polyalphabetic substitution.

How it works

At its core, the Vigenère cipher is several Caesar ciphers, with a different shift value depending on the key. It can be computed simply by hand, through the use of a Vigenère table. In code, it can be done using modulo arithmetic.

Encoding

To encode, we first convert every letter to a number between 0 and 25, where A is 0, and Z is 25. If the key is shorter than the message, it is repeated until they are the same length, i.e. if the message is cryptography, and the key is secretkey:

msg = cryptography
key = secretkeysec

The ith character of the output O, can be computed from the message M, and key K using the follwing formula:

O[i] = (M[i] + K[i]) mod 26
Decoding

Decoding the output O, into the message M knowing the key K, is just as simple:

M[i] = (O[i] - K[i]) mod 26


TEA (Tiny Encryption Algorithm) is a block cipher notable for its simplicity of description and implementation, typically a few lines of code. TEA Encrypt & Decrypt is a free online tool that for Tiny Encryption Algorithm Encrypt & Decrypt.

TEA Encrypt & Decrypt

TEA (Tiny Encryption Algorithm) is a block cipher notable for its simplicity of description and implementation, typically a few lines of code. TEA Encrypt & Decrypt is a free online tool that for Tiny Encryption Algorithm Encrypt & Decrypt.
XTEA (eXtended TEA) is a block cipher designed to correct weaknesses in TEA. XTEA Encrypt & Decrypt is a free online tool that for eXtended TEA cipher Encrypt & Decrypt.

XTEA Encrypt & Decrypt

XTEA (eXtended TEA) is a block cipher designed to correct weaknesses in TEA. XTEA Encrypt & Decrypt is a free online tool that for eXtended TEA cipher Encrypt & Decrypt.
XXTEA Encrypt & Decrypt is a free online tool that for Corrected Block TEA cipher Encrypt & Decrypt. XXTEA (Corrected Block TEA) is a block cipher designed to correct weaknesses in the original Block TEA.

XXTEA Encrypt & Decrypt

XXTEA Encrypt & Decrypt is a free online tool that for Corrected Block TEA cipher Encrypt & Decrypt. XXTEA (Corrected Block TEA) is a block cipher designed to correct weaknesses in the original Block TEA.
MD5 Encrypt is a process of using the MD5 algorithm to transform a string of any length into a hash. You can use this online tool to perform MD5 Encrypt on any string you want.

MD5 Encrypt

MD5 Encrypt is a process of using the MD5 algorithm to transform a string of any length into a hash. You can use this online tool to perform MD5 Encrypt on any string you want.