Fun with Cryptography The Science of Secrecy
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 CAESAR CIPHER Choose plain text Choose a key in the range [1..25] For each letter: 1. find the position of the letter 2. if encrypt, add key to the position 3. if decrypt, subtract key from position 4. if the result is negative, add 26 5. divide the result by by 26 6. find the remainder in the table 7. the character is above the remainder Encrypt Letter = ‘D’, Key = 24 Sum = 26. 27 % 26 = 1. ‘B’ is at position 1 Decrypt Letter = ‘B’, Key = 24 1 – 24 = -23. - 23 + 26 = 3. 3 % 26 = 3 ‘D’ is at position 3 VIGNERE CIPHER Choose a plain text Choose a key word Write the key word over the plain text For each letter and corresponding key letter: find the position of the letter in the key find the position of the letter in the plaintext below the key if encrypt, add what’s found in step 1 to what’s found in step 2 if decrypt, subtract what’s found in step 1 to what’s found in step 2 if the result is negative, add 26 divide the result by 26. Find the remainder in the table above the character is above the remainder Key = GOZAGS Plain Text = COMPUTERSCIENCE G O Z A S C M P U T E R I N