[ pycrypto-Bugs-1559789 ] AES MODE_CBC require multiple of 16 bytes to work?
"SourceForge.net" <[email protected]> Tue, 01 May 2007 14:56:40 -0700
| Newsgroups | gmane.comp.python.cryptography.cvs |
|---|---|
| Message-ID | <[email protected]> |
Bugs item #1559789, was opened at 2006-09-16 15:11
Message generated for change (Comment added) made by dobesv
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=120937&aid=1559789&group_id=20937
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Nobody/Anonymous (nobody)
Summary: AES MODE_CBC require multiple of 16 bytes to work?
Initial Comment:
It seems to me that the CBC algorithm is implemented a
little odd...
When using the CBC mode it should be possible to pass
data with lengths not a multiple of 16?
The following code produces the error:
from Crypto.Cipher import AES
a = AES.new('abcdefghabcdefgh', AES.MODE_CBC)
a.encrypt('This is a test ')
----------------------------------------------------------------------
Comment By: Dobes V (dobesv)
Date: 2007-05-01 21:56
Message:
Logged In: YES
user_id=400635
Originator: NO
For CBC, there's no standard padding scheme and the algorithm requires
that you encrypt an even block in length.
----------------------------------------------------------------------
Comment By: Dobes V (dobesv)
Date: 2007-01-12 21:06
Message:
Logged In: YES
user_id=400635
Originator: NO
Actually, no. With CBC each block is XOR'ed with the next, one complete
block at a time.
You're probably thinking of CFB.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=120937&aid=1559789&group_id=20937
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/