From Wikipedia, the free encyclopedia
In cryptography, a Caesar cipher, also known as Caesar's cipher, the shift cipher, Caesar's code, or Caesar shift, is one of the simplest and most widely known encryption techniques. It is a type of substitution cipher in which each letter in the plaintext is replaced by a letter some fixed number of positions down the alphabet. For example, with a left shift of 3, D would be replaced by A, E would become B, and so on. The method is named after Julius Caesar, who used it in his private correspondence.
Plain : ABCDEFGHIJKLMNOPQRSTUVWXYZ
Cipher: XYZABCDEFGHIJKLMNOPQRSTUVW
Plaintext : THE QUICK BROWN FOX JUMPS OVER THE LAZY DOG
Ciphertext: QEB NRFZH YOLTK CLU GRJMP LSBO QEB IXWV ALD
CipherDisk2000 invented by Leon Battista Alberti 1404 - 1472
Source: Wikipedia
The cipher disk illustration was inspired by Alberti's cipher disk, although his disk had the outer disk as the rotating disk and it was also in the reverse order compared to the inner disk.
This caesar cipher program encrypts only uppercase letters and no other characters. Modelled closely to the caesar cipher used before common era.
pip install jc-cipher
jc-cipher
from caesar_cipher import encryption as ce
from caesar_cipher import decryption as de