


Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!



The purpose of this lab is to implement the following algorithms in MATLAB:
Polyalphabetic ciphers are based on substitution or transposition mechanisms. Improve security using multiple cipher alphabets. It is a combination of separate monoalphabetic ciphers. Make cryptanalysis harder with more alphabets to guess and flatter frequency distribution. Use a key (or sometimes called key word ) to select which alphabet is used for each letter of the message. The length of the key is sometimes called the period of the encryption. Use each alphabet in turn and repeat from start after end of key is reached. The simplest polyalphabetic substitution cipher is called “Vigenère” Effectively multiple Caesar ciphers Key is multiple letters long K = k 1 k 2 ... kd ith^ letter specifies ith^ alphabet to use and use each alphabet in turn. Repeat from start after d letters in message Decryption simply works in reverse Vigenere Cipher Write the plaintext out. Write the keyword repeated above it. Use each key letter as a Caesar cipher key. Lab#03: Classical Encryption Techniques (Polyalphabetic ciphers)
Encrypt the corresponding plaintext letter For Encryption Ci = Pi + ki For Decryption Pi = Ci - ki Use the same concept of Ceasar cipher or monoalphabetic for letter look up using find() command. Hill Cipher In classical cryptography, the Hill cipher is a polygraphic substitution cipher based on linear algebra. Each letter is represented by a number modulo 26. Often the simple scheme A = 0, B = 1, ..., Z = 25 is used, but this is not an essential feature of the cipher. To encrypt a message, each block of n letters (considered as an n -component vector) is multiplied by an invertible n × n matrix, against modulus 26. To decrypt the message, each block is multiplied by the inverse of the matrix used for encryption. Lab#03: Classical Encryption Techniques (Polyalphabetic ciphers)
Matlab Code: A simple tool for such technique is to use the transpose operator You can use the reshape() command according to the depth parameter For decryption, use the inverse of the key to rearrange the ciphertext back to plaintext