[pycrypto] RSA importKey

François Santy francoissanty at gmail.com
Fri Nov 12 05:19:53 CST 2010


Hi everybody !

I'm currently working with pycrypto and I want to import public and private
keys from DER files.
I found a piece of code that shows how to proceed, but it isn't working
anyway !
Here is the code I'm using:

f = file("./public_key.der")
key = RSA.importKey(f.read())

It tells me *'module' object has no attribute 'importKey'. *It's rather
strange since the method appears explicitely in the file
/lib/Crypto/PublicKey/RSA.py*.*
*
*
What am I doing wrong ?

Thanks.

-- 
François S.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.dlitz.net/pipermail/pycrypto/attachments/20101112/cfba0700/attachment.htm 


More information about the pycrypto mailing list