AES - CBC Mode
AES Cipher Block Chaining is the most commonly used mode of operation. It uses the previous output to xor the next input.
Definition
Attacks
Bit flipping attack (CPA) - Wikipedia CryptoHack
If an attacker can change the ciphertext, they can also alter the plaintext because of the XOR operation in the decryption process. (Homomorphic property of XOR, used in the previous block)
If you want to change the first block of plaintext, you need to be able to edit the IV, as the first block of plaintext is XORed with the IV. If you don’t have access to it, you can try to make the target system ignore the first block and edit the remainder instead. (example: json cookie {admin=False;randomstuff=whatever} -> {admin=False;rando;admin=True} )
Custom exploit script from this Github gist
IV = Key - StackExchange CryptoHack
When the IV is chosen as the key, AES becomes insecure. The Key can be leaked if you have a decryption oracle (CCA).