<div dir="ltr">Hi, I was looking at the pycrypto pull request <a href="https://github.com/dlitz/pycrypto/pull/32">https://github.com/dlitz/pycrypto/pull/32</a>.  Just a few comments...<div style><br></div><div style>* For readability can you pep8 format the code?</div>
<div style>* RSA, for import/export the protection parameter maybe rename to algo or wrap algo?  It evolves from: 'protection' to 'wrap_algo' to 'mode' as it goes down the call stack.</div><div style>
* Also maybe make this parameter an enum/value?  Since the long string can be error prone, low level code would need to change anyway if it were either string or int if we support more modes.</div><div style>* And last but not least... I'm new to this email list and not sure how often pull requests are accepted but maybe you could reduce the amount of features going in?  I know you have another one, 51, after this... Maintainer may reluctant to do massive changes all at once?</div>
<div style><br></div><div style>Anyway just ideas...</div><div style>Thanks for your time,</div><div style>Sincerely,</div><div style>Kurt</div><div style><br></div><div style><br></div>







</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jul 3, 2013 at 2:26 PM, Legrandin <span dir="ltr"><<a href="mailto:helderijs@gmail.com" target="_blank">helderijs@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I find 3DES is as good as AES for most practical purposes.<br>
The main limitation I see is that the current RSA.exportKey() uses<br>
PEM-level encryption and the MD5-based EVP_BytesToKey function for key<br>
derivation. Nowadays that is *really* weak.<br>
<br>
I opened a pull request [1] with a proposal for adding PKCS#8, since<br>
it is widely used and it makes it easier to have pluggable algorithms<br>
(the default combination being PBKDF2WithHMAC-SHA1AndDES-EDE3-CBC but<br>
PBKDF2WithHMAC-SHA1AndAES128-CBC is available too). It took a few<br>
iterations, but I am pretty happy with it.<br>
On top of that I have also just added exportKey/importKey to DSA [2].<br>
<br>
Feedback is welcome.<br>
<br>
[1] <a href="https://github.com/dlitz/pycrypto/pull/32" target="_blank">https://github.com/dlitz/pycrypto/pull/32</a><br>
[2] <a href="https://github.com/dlitz/pycrypto/pull/51" target="_blank">https://github.com/dlitz/pycrypto/pull/51</a><br>
<br>
2013/6/28 Kurt Vogel <<a href="mailto:kvogel@mdcom.com">kvogel@mdcom.com</a>>:<br>
> Hello,<br>
><br>
> Wondering if it would be worthwhile to add more encryption options to rsa<br>
> exportKey() function rather than just DES3?  As the default for ssh-keygen<br>
> -t rsa export is 128-bit AES.  And maybe allow plug-able hash algorithms<br>
> such as PBKDF2, Bcrypt, etc.?<br>
><br>
> Thanks,<br>
> Kurt<br>
><br>
><br>
><br>
><br>
> _______________________________________________<br>
> pycrypto mailing list<br>
> <a href="mailto:pycrypto@lists.dlitz.net">pycrypto@lists.dlitz.net</a><br>
> <a href="http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto" target="_blank">http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto</a><br>
><br>
_______________________________________________<br>
pycrypto mailing list<br>
<a href="mailto:pycrypto@lists.dlitz.net">pycrypto@lists.dlitz.net</a><br>
<a href="http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto" target="_blank">http://lists.dlitz.net/cgi-bin/mailman/listinfo/pycrypto</a><br>
</blockquote></div><br></div>