1 / 9

Encrypting with Block Ciphers

Encrypting with Block Ciphers. CS 470 Introduction to Applied Cryptography Instructor: Ali Aydin Selcuk. How to Encrypt with a Block Cipher?. Electronic Codebook (ECB) Mode: The naive way.

chailyn
Download Presentation

Encrypting with Block Ciphers

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. Encryptingwith Block Ciphers CS 470 Introduction to Applied Cryptography Instructor: Ali Aydin Selcuk Modes of Operation

  2. How to Encrypt with a Block Cipher? Electronic Codebook (ECB) Mode: • The naive way. • The plaintext is divided into blocks Pi ,each block is encrypted independently:Ci = E(Pi)Pi = D(Ci) • Problem: Leaks information about identical blocks Modes of Operation

  3. An Illustration – The Plaintext Modes of Operation

  4. An Illustration – ECB Encrypted Modes of Operation

  5. Cipher Block Chaining (CBC) • Add randomization to the plaintext by mixing with the previous ciphertext: Ci = E(PiCi-1) Pi = D(Ci) Ci-1 • Initialization Vector (IV): used instead of C0 when encrypting/decrypting the first block. (not a secret) • Most common mode in practice • Features: • Error propagation: 1 wrong bit corrupts 1 block + 1 bit • Allows random access to the ciphertext • Decryption is parallelizable Modes of Operation

  6. An Illustration – CBC Encrypted Modes of Operation

  7. Output Feedback (OFB) Mode • Block cipher is used as the PRNG in a stream cipher. • A key stream is generated from the output: Oi = E(Oi-1) Ci = Pi Oi Pi = Ci Oi • IV used for O0 • Features: • Error propagation minimal (bit for bit) • Preprocessing possible (may be good for multimedia) • Doesn’t allow random access; not parallelizable Modes of Operation

  8. Cipher Feedback (CFB) Mode • A key stream is generated from the ciphertext: Oi = E(Ci-1) Ci = Pi Oi Pi = Ci Oi • IV used for C0 • Features: • Error propagation: 1 bit + 1 block • Allows random access • Decryption is parallelizable Modes of Operation

  9. Counter (CTR) Mode • A key stream is generated by encrypting a counter: Ci = Pi E(IV + i) Pi = Ci E(IV + i) • Features: • Error propagation minimal (bit for bit) • Preprocessing possible • Allows random access • Both encryption and decryption are parallelizable Modes of Operation

More Related