Question

Assuming you are using a 64-bit (8-byte) block cipher in CBC mode. Show the results of...

Assuming you are using a 64-bit (8-byte) block cipher in CBC mode. Show the results of padding the following plaintexts so they can fit into an even number of blocks.

(A) 0f8353c2 8e1ff6

(B) 8c521e

(C) c1

(D) 9f6bef2c 902fe4ba

Homework Answers

Answer #1

We will use PKCS5 padding. It is most common type of padding.

In PKCS5, the padding bytes have thesame value and is equal to the number of padding bytes

I will write the padded bytes in bold

(A) 0f8353c2 8e1ff6

Here we need 1 padding byte, and the value will be 01

It is given that block size = 8 bytes

Block 1 = 0f8353c2

Block 2 = 8e1ff601

(B) 8c521e

Here we need 5 padding byte, and the value will be 05

Block 1 = 8c521e05

Block 2 = 05050505

(C) c1

Here we need 7 padding bytes, so the value will be 07

Block 1 = c1070707

Block 2 = 07070707

(D) 9f6bef2c 902fe4ba

Here we don't need any padding bytes

Block 1 = 9f6bef2c

Block 2 = 902fe4ba

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
This question concerns block cipher modes. We will use a simple affine cipher, which can be...
This question concerns block cipher modes. We will use a simple affine cipher, which can be expressed in C as follows. char cipher(unsigned char block, char key) { return (key+11*block)%256; } Note that the block size is 8 bits, which is one byte (and one ASCII character). We will work with the fixed key 0x08. We now encrypt various plaintexts using modes for this cipher. In every case in which the mode requires an IV, the IV will be 0xAA....
We studied three different modes of operations: ECB, CBC, OFB. One mode may be better than...
We studied three different modes of operations: ECB, CBC, OFB. One mode may be better than another according to a particular criterion. For the following, you don’t have to give any explanations, just state which of the two modes is better according to that criterion: (a) Preventing BG from building a code book of matching P, C pairs. Which is better: OFB or ECB? (b) Being able to encrypt blocks in parallel: Which is better: CBC or ECB? (c) Preventing...
Assume a computer is using signed magnitude base 2 representation to store 8-bit values. Further, assume...
Assume a computer is using signed magnitude base 2 representation to store 8-bit values. Further, assume you have a program which can display the contents of 1-byte memory locations. However, the program displays hex (as a shorthand) instead of binary. What decimal values are represented by the following: (a) C3 (b) 6E Repeat the above, but assume the numbers are stored as 8-bit 2’s complement base 2.
A). Convert following decimal integers to 8-bit two's complement binary numbers using any method . Explain...
A). Convert following decimal integers to 8-bit two's complement binary numbers using any method . Explain why, If decimal number cannot be represented with 8 bits. a. -46 b. -63 c. 118 d. -128 e. 128 B). Perform following operations by converting the decimal numbers to 8-bit two’s complement binary. Check results by converting final result to decimal a. 94-53 b. 15–84
1) Suppose you have a 26 factorial experiment that you want to put into 8 blocks....
1) Suppose you have a 26 factorial experiment that you want to put into 8 blocks. a. Identify l, where 2l = the number of blocks. b. What is the block size? Remember we have 64 total treatment combinations that we want to partition into 8 blocks of equal size. c. How many effects will we need to confound with blocks? d. Suppose we choose to confound the effects ABC, CDE, and DEF to construct our design. Describe how we...
2 Convert each of the following octal numbers to 10-bit binary, hexadecimal, and decimal. Show your...
2 Convert each of the following octal numbers to 10-bit binary, hexadecimal, and decimal. Show your work. (a) 368 (b) 7568 3 Convert the following binary values into Decimal, Octal and hexadecimal. Show your work. (a) 111010101011112 (b) 1010111011001102 (c) 1011101010001112 (d) 1111101011102 4 Convert the following hexadecimal numbers to 16-bit binary and decimal numbers. Show your work. (a) FE9816 (b) FCAD16 (c) B00C16 (d) FEDF16 5 Perform the addition on the following unsigned binary numbers. Indicate whether or not...
show data visualizations and comment . create data visualizations before and after the results that you...
show data visualizations and comment . create data visualizations before and after the results that you would present for the following: 1)Analyze the correlation for the following data: Orifice Diameter Radon Released (%) 0.37 80 83 83 85 0.51 75 75 79 79 0.71 74 73 76 77 1.02 67 72 74 74 1.40 62 62 67 69 1.99 60 61 64 66 2)A company operates four machines three shifts each day. From production records, the following data on the...
1. The memory units that follow are specified by the number of words times the number...
1. The memory units that follow are specified by the number of words times the number of bits per word. How many address lines and input/output data lines are needed in each case? (a) 8K X 16 (b) 2G X 8 (c) 16M X 32 (d) 256K X 64 2. Give the number of bytes stored in each memory unit in question 1. 3. Word number 563 decimal in the memory shown in Fig. 7.3 (see Mano-Ch7.pdf) contains the binary...
PLEASE ANSWER ALL PARTS AND SHOW ALL WORK! In this section, all collisions will be completely...
PLEASE ANSWER ALL PARTS AND SHOW ALL WORK! In this section, all collisions will be completely elastic – that is, the total kinetic energy of the system will be constant throughout. Also, the collisions are entirely one-dimensional, with all motion taking place in either the northward or southward direction. The setting: a room with a frictionless floor. A block of mass 1 kg is placed on the floor and initially pushed northward, whereupon it begins sliding with a constant speed...
Q1)Among the following control mode, which one would you choose to control the level of a...
Q1)Among the following control mode, which one would you choose to control the level of a process tank A. Manual B. P C. PI D. PID Q2) Explain the purpose of the second tank in a non-interacting set up Q3) In the cascade control set-up, which is the measured variable for the slave controller? Q4) In cascade controller, which of the loop (inner or outer) is a feed-forward loop? Explain why? Q5) For the non-interacting set-up with no controller, your...