Given the key, the plain text and the cipher text can I calculate the IV used in CBC mode? If I have the plain text, the ciphertext and the key for an AES-128 CBC operation, can I determine the IV, even if I don't know the padding (assuming the padding follows one of the more common formats)?

I believe it should be possible since my understanding is that the IV is only used as an initial XOR of the plain text in encryption, and should, therefore, be able to be available like this:

AESDecrypt(key, ciphertext) =&gt; (PlainText XOR IV);
IV = ((Plaintext XOR IV) XOR (Plaintext))


Is this correct?
It is simple.

Just decrypt first 8 bytes encrypted buffer(1 block) in ECB mode (You only need encrypted buffer and key to do so) and then xor the result with the input buffer. Result will be IV.

In decryption of CBC, IV just affect first block. That's why only first block is incorrect in your case.