I'm supposed to write a script that will get the plaintext of a message which is firstly coded in base64, then URL coded (encoded ciphertext in AES-256-CBC). Padding is used as well such that the encoded message is a multiple of the block size.
The message is this:
If I type this in a specific site (server), I get certain messages (for example if padding is invalid / valid, bad request if the length is wrong,..).
But I don't know how I shall use padding oracle attack on this to find the plaintext. I don't care about the program at all, I just like to understand it first.
So I would start by decoding the message such that I just have it in base64:
And at this part I'm not sure how to continue or rather say start the padding oracle attack. I think I need to start at the very last block, very last byte and go back. So begin with
0x01 at the end and see if the server gives a valid padding result? Would I need to remove the first two
"=" chracters? I don't think so because they are part of the base64, so rather start by removing
FA instead and replace with
I hope you can give me some hints really I have checked so many site and books but there isn't as much information as I imagined :/
I'm far away from writing a script for that but I just like to understand it at least.