Applied Cryptography

Which of the following correctly describes the 96-bit nonce (IV) used in AES-GCM?

  1. AIt need not be secret and may be generated by a counter, but the same value must never be used twice with the same key
  2. BIf an attacker learns it, the plaintext leaks, so it must be kept secret and stored securely just like the key
  3. CIt must be chosen at random every time, and generating it with a counter incremented by 1 destroys security
Show answer and explanation

Answer: A. It need not be secret and may be generated by a counter, but the same value must never be used twice with the same key

What is required of a GCM nonce is that its values never repeat (are unique) under the same key. It need not be secret, and a counter that counts transmissions satisfies the requirement. Using the same nonce twice with the same key leaks the XOR of the plaintexts, as in CTR mode, and also allows the value used for authentication to be recovered, so tags may be forged. When nonces are chosen at random, a limit is placed on the number of encryptions under one key to avoid accidental repeats (2^32 in NIST SP 800-38D).

  • A. Correct. Uniqueness is the requirement; unpredictability is not.
  • B. The nonce is normally sent together with the ciphertext and need not be secret.
  • C. A counter is safe as long as values never repeat. The requirement differs from that for the IV of CBC mode.
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. 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?
  2. Which of the following correctly describes the hash functions SHA-2 and SHA-3?
  3. Using the hash SHA-256(K ‖ m) of a secret key K concatenated with a message m as a tag for detecting tampering is considered dangerous. Which of the following is the reason?
  4. Let 1 GiB = 2³⁰ bytes and 1 EiB = 2⁶⁰ bytes. A block cipher with a 64-bit block (such as 3DES) is used in CBC mode to encrypt a large amount of data under one key. Treating the ciphertext blocks as random 64-bit values, which of the following is the approximate amount of data at which, by the birthday paradox, the probability that a pair of identical ciphertext blocks appears can no longer be ignored?
  5. In protocols such as TLS 1.3, the shared secret obtained from an ECDHE key exchange is not used directly as an encryption key; instead keys are made by passing it through a key derivation function (KDF) such as HKDF. Which of the following is an appropriate reason?

Comparisons in this topic