1 / 55

Lecture 3

Lecture 3. Transposition Ciphers. Transposition Ciphers. now consider classical transposition or permutation ciphers these hide the message by rearranging the letter order without altering the actual letters used

Download Presentation

Lecture 3

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Lecture 3

  2. Transposition Ciphers

  3. Transposition Ciphers • now consider classical transposition or permutation ciphers • these hide the message by rearranging the letter order • without altering the actual letters used • can recognise these since have the same frequency distribution as the original text

  4. Rail Fence cipher • write message letters out diagonally over a number of rows • then read off cipher row by row • eg. write message out as: m e m a t r h t g p r y e t e f e t e o a a t • giving ciphertext MEMATRHTGPRYETEFETEOAAT

  5. Decryption of Rail Fence • Divide the statement by 2 • If odd number let the first part is more than 1 • Put he first part above • And the second part below • Read the statement as diagonal

  6. Reverse cipher • Write the message backwards • Ex: • Plain: I came I saw I conq uered • Cipher: d ereu q noci w asie maci

  7. Decryption of Reverse cipher • Write the cipher message backwards

  8. Row Transposition Ciphers • a more complex transposition • write letters of message out in rows over a specified number of columns (key length) • Then reorder the columns according to some key before reading off the rows Key : 41532 Plain text : the simplest possible transpositions.

  9. Row Transposition Ciphers • Make the statement in 5 columns: • “the simplest possible transpositions”

  10. Row Transposition Ciphers

  11. Row Transposition Ciphers • Make the statement in 5 columns: Key: 41532 Cipher: STIEH EMSLP STSOP EITLB SRPNA TOIIS XOXSN

  12. The same plain with another key The key : 15342 The cipher is :TIESH MSLEP TSOSP ITLEB RPNSA OIITS OXSXN

  13. Row transposition : Example 1 • Plain text : " laser beams can be modulated to carry more intelligence than radio” • Key is: 6 3 4 1 2 5 7

  14. Row transposition : Example 1 • " laser beams can be modulated to carry more intelligence than radio”

  15. Row transposition : Example 1 • KEY : 6 3 4 1 2 5 7

  16. Row transposition : Example 1 • Solution is : • “bselarenscamablodemuacdtteoarymrroelteinlitncgeehiraando”

  17. Another Example: 2 • Let • key : COMPUTER • PLAIN: “a convenient way to express the permutation “

  18. Another Example • Let • key : COMPUTER • Key will be:

  19. Another Example Key: 14358726 Plain: a convenient way to the permutation Cipher: ANOVINCE EW TAOTNY TPEEUMHR TITOXXAN

  20. Row Transposition Ciphers • a more complex transposition • write letters of message out in rows over a specified number of columns • then reorder the columns according to some key before reading off the rows Key: 3 4 2 1 5 6 7 Plaintext: a t t a c k p o s t p o n e d u n t i l t w o a m x y z Ciphertext: TTNAAPTMTSUOAODWCOIXKNLYPETZ

  21. Decryption of a Row Transposition cipher consists of: • writing the message out in rows • reading off the message by reordering columns

  22. CIPHER TEXT : LHEL VOEE BRYOXDYX • THE solution : hello every body

  23. Decryption of a Row Transposition cipher example: Cipher text = OANTTOSRGINCHRPE Key: IVAN

  24. The solution is : not a strong cipher

  25. Product Ciphers • ciphers using substitutions or transpositions are not secure because of language characteristics • hence consider using several ciphers in succession to make harder: • two substitutions make a more complex substitution • two transpositions make more complex transposition • but a substitution followed by a transposition makes a new much harder cipher • this is bridge from classical to modern ciphers

  26. Product Ciphers • before modern ciphers, rotor machines were most common product cipher • were widely used in WW2 • German Enigma • implemented a very complex, varying substitution cipher • used a series of cylinders, each giving one substitution, which rotated and changed after each letter was encrypted • with 3 cylinders have 263 =17576 alphabets

  27. Block CiphersDr. NerminHamza

  28. Modern Cryptographic Techniques • Modern cipher system : • Symmetric • Asymmetric • Symmetric cryptography: • Stream cipher • Block cipher

  29. Modern Cryptographic Techniques

  30. Stream cipher • Stream ciphers:where plaintext bits are combined with a pseudorandom cipher bit stream (key stream), typically by an • exclusive-or (xor) operation. In a stream cipher, the plaintext digits are encrypted one at a time, and the transformation of successive digits varies during the encryption.

  31. Stream cipher Stream ciphers:- process messages a bit or byte at a time when en/decrypting

  32. Stream cipher • 2 types: • Synchronous stream • Asynchronous stream • Synchronousstream ciphers where the key stream depends only on the key, • Asynchronous stream ones where the key stream also depends on the ciphertext.

  33. Stream cipher

  34. Stream cipher • Definition Stream Cipher Encryption and Decryption • The plaintext, the ciphertext and the key stream consist of individual bits, i.e., xi,yi, si ∈ {0,1}. • Encryption: yi= esi(xi) ≡ xi+simod 2. • Decryption: xi= dsi(yi) ≡ yi+simod 2.

  35. Modern Block Ciphers • look at modern block ciphers • one of the most widely used types of cryptographic algorithms • provide secrecy /authentication services • focus on DES (Data Encryption Standard) • to illustrate block cipher design principles

  36. Block cipher • Block cipher scheme :encrypts one block of data at a time using the same key on each block. • In general, the same plaintext block will always be encrypted to the same cipher text if using the same key in a block cipher whereas the same plaintext will be encrypted to different cipher text in a stream cipher.

  37. Block cipher • block ciphers: process messages in blocks, each of which is then en/decrypted • like a substitution on very big characters • 64-bits or more

  38. Block modes • Electronic Codebook (ECB) mode • Cipher Block Chaining (CBC) mode • Cipher Feedback (CFB) • Output Feedback (OFB) mode

  39. Block modes • Electronic Codebook (ECB) mode: The simplicity of the encryption modes is the electronic codebook (ECB) mode, in which the message is split into blocks and each is encrypted separately

  40. Block modes

  41. Block modes • Cipher Block Chaining (CBC) mode In the cipher-block chaining (CBC) mode, each block of the plaintext is XORed with the previous cipher text block before being encrypted. This way, each cipher text block is dependent on all plaintext blocks up to that point.

  42. Block modes

  43. Block modes

  44. Block modes • Cipher Block Chaining (CBC) mode

  45. Block modes • Cipher Feedback (CFB) Cipher feedback mode converts the block cipher into a stream cipher: they generate key-stream blocks, which then are XORed with the plaintext blocks to get the cipher-text. Just as with other stream ciphers, flipping a bit in the cipher-text produces a flipped bit in the plaintext at the same location. With cipher feedback, a key-stream block is computed by encrypting the previous cipher-text block.

  46. Block modes

  47. Block modes

  48. Block modes • Cipher Feedback (CFB)

  49. Block modes • Output Feedback (OFB) mode OFB is similar to CFB but with small differences, where the Output feedback generates the next key-stream block by encrypting the last one.

  50. Block modes

More Related