title: How do I implement CBC mode?
body: <p>My problem lies around the AES encryption algorithm and implementing an IV into the algorithm. I have the ECB version of AES working and I have thoroughly tested it. I'm trying to make it more secure by adding in an IV. I am looking to understand it better by knowing how the IV is implemented in the algorithm.</p>
  
  <p>I am understanding that the IV is XOR'd with the plain text before encryption, and the IV is then stored with the encrypted data for decryption. But then when I go to decrypt, do I do the same XOR computation after the decryption process?</p>
  
  <p>I tried the above process and my test for encryption and decryption work with the same values, but when I put the two processes side by side I get values very close to one another, but it doesn't seem to be working quite right. Not asking for code to be fixed, just the process laid out for me so that I know I'm doing this correctly. Thanks.</p>