[pycrypto] RSA exportKey() changes set in stone for 2.7?

Dwayne Litzenberger dlitz at dlitz.net
Sun Sep 29 18:52:11 PDT 2013

On Wed, Jul 17, 2013 at 01:33:41AM -0700, Kurt Vogel wrote:
>Hi, quick question for the group and maintainer...
>I am about ready to deploy a project and wondering how set we are on the
>format of rsa.exportKey() for next pycrypto?
>Is it safe to include in our requirements.pip (for now) a reference to
>https://github.com/dlitz/pycrypto master branch?  And export my keys with
>the new protection scheme?  And consequently matching importKey().
>It would be super nice if we could add **kwargs for iteration_count and
>salt_size to export() but beggars can't be choosers :)  It seems a simple
>enough change and looks like importKey() reads those fields in, I'd do it
>myself but would like any thoughts/opinions?

Hi Kurt,

The exportKey API should be considered experimental at this point.  
There are things about it that don't really make sense (e.g. the 
`pkcs=1` parameter, which doesn't make any sense if you want to expoer 
in OpenPGP format, for example).  Realistically, it should probably be 
removed from Crypto.PublicKey and placed into Crypto.IO, but I'm not 
sure of exactly when that will happen.

- Dwayne

Dwayne C. Litzenberger <dlitz at dlitz.net>
  OpenPGP: 19E1 1FE8 B3CF F273 ED17  4A24 928C EC13 39C2 5CF7

More information about the pycrypto mailing list