Chapter7Notes

# Chapter7Notes - Chapter 7 Notes Block-Cipher Modes 1...

This preview shows pages 1–4. Sign up to view the full content.

Chapter 7 Notes Block-Cipher Modes 1) Electronic Code Book(ECB): This is the typical manner in which block cipher are executed. Simply grab n bits of the plaintext at a time, where n is the block size, and then encrypt them using the algorithm, and output the corresponding ciphertext. Repeat for each subsequent block. 2) Cipher Block Chaining(CBC) mode: C 0 = IV (initialization vector) i = 1 while (!done) C i = e K (C i-1 M i ) M i and C i stand for the ith 64 bit block of plain and cipher text respectively. 3) Output Feedback Mode(OFB): This is a stream cipher, which means that we obtain the ciphertext by XORing the plaintext with a keystream. The keystream is generated with the key and the block cipher system being used. K 0 = IV i = 1 while (!done) { K i = e K (K i-1 ) C i = M i K i } 4) Cipher Feedback Mode(CFB): This is also a stream cipher, except that the keystream is generated by encrypting the ciphertext instead of the plaintext. C 0 = IV i = 1 while (!done) { K i = e K (C i-1 ) C i = M i K i }

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
5) Counter Mode (CTR) Here, the counter array stores known, prechosen values, so that each block could be encrypted in parallel. It could just store, 1, 2, 3, etc. Or, the initial counter value could be provided and then future counter values could be based on it, but if this were the case, then the counter values would have to be determined sequentially. i = 1 while (!done) { K i = e K (counter[i]) C i = M i K i } Data Encryption Standard(DES) Here is the basic algorithm used for DES: To encrypt a plaintext x of 64 bits and a secret key K of 56 bits do the following: 1) Compute x 0 = IP(x), a fixed permutation of the bits in x. IP is specified in the text. 2) Let x i = L i R i , for 0 i 16, where L i is the 32 leftmost bits of x i and R i is the 32 rightmost bits of x i . Make the following sequence of computations: for (i=1 to 16) { L i = R i-1 R i = L i-1 f(R i-1 , K i ) } Essentially, each loop iteration is known as a Feistel round. (Feistel is the creator of DES.) DEs comprises 16 of these rounds. Each round encrypts ½ of the bits from the pervious round. The function f and the key for the ith round K i will be discussed in detail later in these notes. 3) y = IP -1 (R 16 L 16 ), this means applying the inverse permutation applied in step 1 to the string R 16 L 16 . (Notice the “reverse” order of the two blocks L 16 and R 16 .) In essence, you would repeat this process for every block of 64 bits that needs to be encrypted. Now, we need to mention the details of step 2. First the function f: The first input to f, R i-1 is 32 bits, while the second input K i is 48 bits from the 56 bits of the key K.
1) Expand the 32 bits of R i-1 to 48 bits using the matrix E, which is also shown in the book. This matrix delineates an ordering of the bits of R i-1 where 16 of the bits are repeated. Let this computed value be E(R i-1 ). 2) Compute E(R

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 07/13/2011 for the course CIS 3362 taught by Professor Staff during the Fall '08 term at University of Central Florida.

### Page1 / 8

Chapter7Notes - Chapter 7 Notes Block-Cipher Modes 1...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online