The Vigenère Cipher is a method of encrypting alphabetic text by using a simple form of polyalphabetic substitution. This program implements the Vigenère Cipher, allowing users to both encrypt and decrypt text using a key of variable length.
The Vigenere cipher is named after the French cryptographer, Blaise de Vigenere. Vigenere ciphers are block ciphers working on blocks of length n, using keys of length n.
This program includes encryption and decryption functionalities for the Vigenere cipher. The user chooses decryption or encryption and supplies the program with a message and a key. Please run the program on your local computer.
- Encrypt text: Convert plaintext to ciphertext using a keyword.
- Decrypt text: Convert ciphertext back to plaintext using the same keyword.
- Python 3.x
No installation is required. You can run the program directly in any Python environment.
To use the program, follow these steps:
-
Run the program:
- Open your terminal or command prompt.
- Navigate to the directory containing the
vigenere_cipher.py
file. - Run the script by typing
python vigenere_cipher.py
.
-
Choose an operation:
- Type
E
to encrypt a message. - Type
D
to decrypt a message.
- Type
-
Input the required information:
- For encryption, enter the plaintext and the keyword.
- For decryption, enter the ciphertext and the keyword.