Vigenère Cipher

This JavaScript program performs encryptions and decryptions using the Vigenère cipher.

The program

Plaintext/ciphertext
Actions

Key:

Instructions

Input the plaintext or ciphertext, enter the key, then press Encrypt or Decrypt.

If Preserve punctuation and case is disabled, then the output is formatted in traditional way: uppercase letters in blocks of 5.

Non-letters are not subjected to encryption or decryption. The key must have at least 1 alphabetic letter. The key is case insensitive, and non-letters are discarded.

This program runs strictly on client side only. No data is communicated to the server when performing encryptions and decryptions.

It is possible to use this cipher in an unbreakable way, since it’s a generalization of the one-time pad. Just ensure that the key is random, unpredictable, uncorrelated with the message, and exactly as long as the message.

Links

Last modified: 2008-04-16-Wed
Created: 2007-08-16-Thu