1
$\begingroup$

If some plaintext encrypted twice with the same AES function (CBC-mode), same IV and same key, is it possible to retrieve either the key or the plaintext?

$\endgroup$
  • $\begingroup$ Key no (AES is believed to protect the private key against any attacks other than related key attacks). $\endgroup$ – Demi May 2 '16 at 21:29
2
$\begingroup$

No, it is not possible.

The encryption step of CBC is $c_i = E(c_{i-1} \oplus p_i)$. When you double encrypt, the previous block ciphertext gets XORed with an independent block cipher output. The only place where something weird could happen is the beginning.

If you assume that the (identical) IV $I$ is prepended to the ciphertext, as is common, you get $I, E(I \oplus p_1), ...$ after the first encryption and then: $$I, E(I \oplus I) = E(0), E(E(0) \oplus E(I \oplus p_1)), ...$$

This is wasteful, easily detectable due to the encryption of the zero block in every message, but not decryptable by an attacker. If the IV is not prepended, it is even more clearly not an issue. (However, there is no reason to believe it would be a good idea to do this either.)

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.