I am currently tackling a challenge involving AES CBC encryption where i have the ability to choose both the IV and the ciphertext, and then provide it to a service. The service decrypts with an unknown (but fixed) key. The goal of the challenge is to provide a specific ciphertext and IV that decrypts to the correct plaintext. I know the exact plaintext that has to be decrypted.

The service provides two different error messages, based on whether the padding is wrong or if the decrypted message is wrong. This leads me to believe this could be some version of a padding oracle attack, albeit a bit different.

Considering I know the desired plaintext and i choose both the IV and Ciphertext, mixed with a potential padding oracle element, how can I generate the correct ciphertext? Thank you in advance.

  • 1
    $\begingroup$ (The padding oracle attack is a decryption oracle) For the attack work you need to modify the previous ciphertext, this is why you need to supply the IV to your advantage. $\endgroup$
    – kelalaka
    Commented May 15 at 18:26