[pycrypto] AES, MODE_CTR
dave.pawson at gmail.com
Thu Dec 5 05:00:30 PST 2013
Thanks Richard. Now working
iv = Random.new().read(AES.block_size)
cipher = AES.new(b' '*16, AES.MODE_CTR, IV=iv, counter=ctr)
ct = cipher.encrypt(pt)
decipher = AES.new(b' '*16, AES.MODE_CTR, IV=iv, counter=ctrr)
ptr = decipher.decrypt(ct)
iv added as suggested.
Does anyone know of any better documentation for Counter and its use please?
On 4 December 2013 17:01, Richard Moore <richmoore44 at gmail.com> wrote:
> You need to reset the counter (or make a new one) before you start to
> decrypt. You also don't seem to be using an IV which would lead to a
> massive security hole.
> pycrypto mailing list
> pycrypto at lists.dlitz.net
XSLT XSL-FO FAQ.
More information about the pycrypto