Applied Cryptography

Which of the following correctly describes a feature of CTR mode (counter mode) of a block cipher?

  1. AEach block is encrypted using the ciphertext of the previous block, so encryption cannot be done in parallel
  2. BPadding to make the plaintext a multiple of the block length is always required
  3. CA value combining a nonce and a counter is encrypted to make a keystream, which is XORed with the plaintext
Show answer and explanation

Answer: C. A value combining a nonce and a counter is encrypted to make a keystream, which is XORed with the plaintext

In CTR mode, a value combining a nonce and a counter incremented by 1 for each block is encrypted with the block cipher, and the output is XORed with the plaintext as a keystream. The keystream for each block can be computed independently of the previous block, so both encryption and decryption can be done in parallel, and any desired position can be decrypted on its own. The keystream can simply be cut to the length of the plaintext, so no padding is needed. Decryption also uses the block cipher only in the encryption direction.

  • A. This is a property of encryption in CBC mode. CTR mode can encrypt in parallel.
  • B. CTR mode cuts the keystream to the length of the plaintext, so no padding is needed.
  • C. Correct. It is a mode that uses a block cipher like a stream cipher.
Practice this topic Back to topic

Books on Applied Cryptography Ad

As an Amazon Associate I earn from qualifying purchases.

More Applied Cryptography questions

  1. In CTR mode, two messages were mistakenly encrypted with the same key and the same nonce. For the byte at one position, the first plaintext P₁ is 01001000 (ASCII "H"), its ciphertext C₁ is 01110100 and the second ciphertext C₂ is 01010101. If the attacker knows P₁, which of the following is the second plaintext P₂ at the same position?
  2. Which of the following does authenticated encryption (AEAD) such as AES-GCM provide in a single operation?
  3. Which of the following correctly describes the 96-bit nonce (IV) used in AES-GCM?
  4. On a certain machine, a brute-force search trying every 56-bit key takes about 20 hours. Which of the following is closest to the time the same machine needs to try every 64-bit key?
  5. Which of the following correctly describes the hash functions SHA-2 and SHA-3?

Comparisons in this topic