AES256 in PyCrypto

mirandacascade at yahoo.com mirandacascade at yahoo.com
Sun Jan 7 16:23:29 EST 2007


Sebastian 'lunar' Wiesner wrote:

> Since you are apparently unable to read to docstrings of this module, I
> will give you a short hint: yes, pycrypto supports AES with 256 bit
> keys.
Thank you for the information.

The material I consulted was:
a) the PyCrypto manual: http://www.amk.ca/python/writing/pycrypt/
b) the .py files that shipped with the PyCrypto package

Is a docstring is the text between the three consecutive quote
characters in a .py file?  The reason for the question is that I looked
at the .py files that shipped with PyCrypto.  Of the various .py files
that shipped with PyCrypto, there were two files (both __init__.py)
that contained information seemed to pertain to AES.  The stuff between
the 3 consecutive quote chars in:
  Crypto.__init__.py
  Crypto.Cipher.__init__.py
make reference to AES, but I wasn't able to determine from what I read
if that was AES256.
Which .py file contain the docstrings that flesh out the information
summarized in the short hint?

Can docstrings be embedded within the .pyd extension modules as well?
Does the AES.pyd extension module have docstrings?  How does one view
the docstrings in a .pyd file?  When I reference AES from the
interactive of Pythonwin:
>>> from Crypto.Cipher import AES
>>> x = AES.new(
As soon as I type the '(' character, the IDE displays:
new(key, [mode], [IV]): Return a new AES encryption object

then when x gets instantiated, and the encrypt method gets called...
>>> x.encrypt(
As soon as I type the '(' character, the IDE displays:
Encrypt the provided string of binary data

I'm guessing that what the IDE is displaying is the first line of what
may be multiple-line docstring that is embedded within the .pyd
extension module?  Might there be more lines in the docstring?

Thank you.




More information about the Python-list mailing list