Substitution Cryptosystems How many possible keys does an affine cipher on have? 7. Encrypt using a rotation cipher over with . 8. Encrypt using an affine cipher over with 9. Cipher X consists of a rotation, and then an affine cipher. What type of cipher is X? 10. Cipher Y is a substitution cipher over . Cipher consists of applying Y twenty-four times. What type of cipher is X? Be as specific as possible. 6.

Cipher FeedBack (CFB) message is treated as a stream of bits or bytes result is feed back for next stage (hence name) standard allows any number of bit (1,8, 64 or 128 etc) to be feed back denoted CFB-1, CFB-8, CFB-64, CFB-128 etc most efficient to use all bits in block (64 or 128) Ci = Pi XOR EK(Ci-1) C-1 = IV Used for stream data encryption

Cipher Feedback Mode (CFB) • Block cipher implemented as a self synchronizing mode • 64-bit CFB or any n-bit CFB • Encryption – Ci = Pi XOR Ek(Ci-1) • Decryption – Pi = Ci XOR Ek(Ci-1) • Initialization vector needed (IV must be unique) • Error Propagation

Flow Chart Cipher Text false false IC<=.0455 Cipher is Playfair false Cipher dist = normal dist Cipher is Vigenere false Error true IC >= .058 true IC = Index of coincidence Same freqs present Shift freq. = normal true true Cipher is Affine Cipher is Caesar true Cipher is transposition

Cryptography Substitution cipher A cipher that substitutes one character with another Caesar cipher A substitution cipher that shifts characters a certain number of positions in the alphabet Transposition ciphers A cipher that rearranges the order of existing characters in a message in a certain way (e.g., a route cipher) 20

In Europe during the Renaissance, cryptography was becoming a routine diplomatic tool Cryptanalysis was moving into the West during the 15th century time By the 18th century the telegraph was invented. During the Civil War U.S. Military Telegraph Corps used route ciphers. Many cryptanalysists invented different ciphers between the 15th and 18th century periods: Giovanni Battista Porta (1535-1615) invented the earliest digraphic cipher. Blaise de Vigenere (1523-1596) invented the first acceptable autokey cipher system. Also the Vigenere Square. Francis Bacon (1561-1626) invented the Bilateral cipher. Thomas Jefferson (1743-1826) invented the wheel cipher. Charles Wheatstone invented the digraphic cipher (playfair cipher).

Encryption Text: Computer Security: Principles and Practice, W Stallings, L Brown Chapter 2 Objectives: The student should be able to: Define authentication, integrity, confidentiality and non-repudiation. Define plaintext, ciphertext, key, P-box, S-box, session key, digital signature, message digest, hash. Demonstrate operation of a simple substitution cipher, permutation cipher, stream cipher, block cipher, block chaining mode cipher. Describe why chaining is advantageous in block ciphers. Define symmetric versus asymmetric encryption algorithms and describe the differences between the two. Define the advantages of secret key and public key algorithms. Describe their functions in relation to authenticity, non-repudiation, integrity, confidentiality, and speed. Describe two methods of producing a hash. Define whether the following protocols support authentication, non-repudiation, integrity, and/or confidentiality via hashing or a type of encryption: AES, HMAC, DES, MD5, RCS, RSA.

Cryptanalysis Overview Method used is based on the amount of information Brute Force: try all possibilities Dictionary Attack: run through a dictionary of words trying to find the key or plaintext Cipher text only Chosen Plaintext: Have the ability to find the cipher text relating to an arbitrary plaintext Chosen Cipher text: can choose an arbitrary cipher text and know the plaintext Adaptive chosen plaintext: determine cipher text based on plaintext using iteration

Substitution Cryptosystems 1. 2. 3. 4. 5. A substitution cipher uses this to represent its key. A rotation cipher uses this to represent its key. An affine cipher uses this to represent its key. How many possible keys does a substitution cipher on have? How many possible keys does a rotation cipher on have?

4. Vigenere Cipher - a polyalphabetic cipher invented by the Frenchman Blaise de Vigenere Cipher in 1585. The value of this cipher was not known until frequency analysis was used to break monoaphabetic ciphers. As a result, this cipher was not used widely until the 1800’s.