Open GoogleCodeExporter opened 9 years ago
Actually it is only the first 16bits that are scrambled and not the first line
Original comment by tomchev....@gmail.com
on 5 Dec 2012 at 9:13
This are the first couple of lines of my decrypted python file:
*COu|/dŏy#rython
# -*- coding: utf8 -*-
#-------------------------------------------------------------------------------
# Name:
and the lines before encryption are:
#!/usr/bin/env python
# -*- coding: utf8 -*-
#-------------------------------------------------------------------------------
# Name:
Original comment by tomchev....@gmail.com
on 5 Dec 2012 at 9:17
Unless I'm misunderstanding, this is correct behavior.
In CBC mode, decryption works by decrypting the block using the key, and then
XORing it with the previous encrypted block. The IV is simply a stand-in for
the "previous encrypted block" of the first block. So, mucking with the IV of
already-encrypted data will only screw up decryption of that first block.
It's only in the encryption phase that a different IV should cause a cascading
change to future blocks.
Original comment by dhamm...@webdevout.net
on 2 Oct 2013 at 1:47
Original issue reported on code.google.com by
tomchev....@gmail.com
on 5 Dec 2012 at 9:02