I have a (unique) situation where I receive data that is a combination of encrypted (with AES-CBC) and clear-text blocks and I cannot tell which blocks are encrypted. I plan to decrypt all of the data, including the clear-text, I receive and store it locally. Before retransmitting the data, I will encrypt it again. I need the blocks that were originally in clear-text to be in their original clear-text form for the retransmission.
If I decrypt the entire original message, even the blocks that were in clear-text, and then re-encrypt it with AES-CBC and the same key used for decryption, will the originally clear-text blocks be the same after re-encryption as they were when they were received.
E(D(M,K),K) = M)
whereE
is encryption,D
is decryption,M
is the message, andK
Is the key. Is this correct? Please provide more background to your question, and explain your own research effort.