Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 362763 - dev-python/pycrypto-2.3: Import key code is not compatible with GMP library
Summary: dev-python/pycrypto-2.3: Import key code is not compatible with GMP library
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL: https://bugs.launchpad.net/pycrypto/+...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-09 19:15 UTC by Pavel Labushev
Modified: 2011-12-17 09:03 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
ebuild patch and files/pycrypto-2.3-gmp.patch in sequence (pycrypto2.patch,3.38 KB, patch)
2011-12-02 10:42 UTC, Ian Delaney (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pavel Labushev 2011-04-09 19:15:37 UTC
Keys imported with RSA.importKey() won't decrypt/sign correctly if the GMP library is installed. See the upstream bug for details and the fix:
https://bugs.launchpad.net/pycrypto/+bug/702835

Reproducible: Always

Steps to Reproduce:
1. $ openssl genrsa > private.key 2>/dev/null
2. $ python -c 'from Crypto.PublicKey import RSA; key = RSA.importKey(open("private.key", "rb").read()); print key.verify("asdf", key.sign("asdf", ""))'
3. The printed value should be True instead of False.
Actual Results:  
Printed "False"

Expected Results:  
Expected "True"
Comment 1 Ian Delaney (RETIRED) gentoo-dev 2011-12-02 10:42:02 UTC
Created attachment 294497 [details, diff]
ebuild patch and files/pycrypto-2.3-gmp.patch in sequence
Comment 2 Arfrever Frehtes Taifersar Arahesis 2011-12-06 03:11:00 UTC
You can use dev-python/pycrypto-2.4.1, which has been available in Progress Overlay since 2011-11-05.
Comment 3 Maxim Koltsov (RETIRED) gentoo-dev 2011-12-17 09:03:27 UTC
This bug is not present in 2.4.1, which i have just added to tree. Just wait for it's stabilization.