diff options
author | Alex Stapleton <alexs@prol.etari.at> | 2014-12-13 19:58:25 +0000 |
---|---|---|
committer | Paul Kehrer <paul.l.kehrer@gmail.com> | 2014-12-17 16:10:03 -0600 |
commit | d7cc80f22f9be184e4ce61c51fd7555b127a8e32 (patch) | |
tree | d0d44f60649434c6caf5410399c80e1a87e403da /src/cryptography/hazmat/backends/openssl/ec.py | |
parent | 4d8de138910628db04a1c861303e744e7f10729a (diff) | |
download | cryptography-d7cc80f22f9be184e4ce61c51fd7555b127a8e32.tar.gz cryptography-d7cc80f22f9be184e4ce61c51fd7555b127a8e32.tar.bz2 cryptography-d7cc80f22f9be184e4ce61c51fd7555b127a8e32.zip |
Set OPENSSL_EC_NAMED_CURVE on our EC_KEY instances
This means any X.509 certs generated from our keys will be encoded
along with the curve OID so that we can still load them afterwards.
Diffstat (limited to 'src/cryptography/hazmat/backends/openssl/ec.py')
-rw-r--r-- | src/cryptography/hazmat/backends/openssl/ec.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cryptography/hazmat/backends/openssl/ec.py b/src/cryptography/hazmat/backends/openssl/ec.py index 56b7893e..9c616a30 100644 --- a/src/cryptography/hazmat/backends/openssl/ec.py +++ b/src/cryptography/hazmat/backends/openssl/ec.py @@ -167,6 +167,8 @@ class _EllipticCurvePrivateKey(object): res = self._backend._lib.EC_KEY_set_public_key(public_ec_key, point) assert res == 1 + self._backend._mark_asn1_named_ec_curve(public_ec_key) + return _EllipticCurvePublicKey( self._backend, public_ec_key ) |