diff options
author | Paul Kehrer <paul.l.kehrer@gmail.com> | 2016-11-19 11:30:25 +0800 |
---|---|---|
committer | Alex Gaynor <alex.gaynor@gmail.com> | 2016-11-18 22:30:25 -0500 |
commit | e09754c74d75c1ba59c989cb053aaf61b519188d (patch) | |
tree | d9859ec0dbdd5af31954f45b73723abf7aac1e4d /src/_cffi_src | |
parent | 84e4e3111d6008373813a7f2810f7ebc2d0f4e46 (diff) | |
download | cryptography-e09754c74d75c1ba59c989cb053aaf61b519188d.tar.gz cryptography-e09754c74d75c1ba59c989cb053aaf61b519188d.tar.bz2 cryptography-e09754c74d75c1ba59c989cb053aaf61b519188d.zip |
add SSL_CTX_set_ecdh_auto where supported (#3250)
In 1.1.0 this is a noop and occurs by default, and this wasn't supported
< 1.0.2
Diffstat (limited to 'src/_cffi_src')
-rw-r--r-- | src/_cffi_src/openssl/ecdh.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/_cffi_src/openssl/ecdh.py b/src/_cffi_src/openssl/ecdh.py index 099f53cb..2dd5fd72 100644 --- a/src/_cffi_src/openssl/ecdh.py +++ b/src/_cffi_src/openssl/ecdh.py @@ -12,6 +12,7 @@ INCLUDES = """ TYPES = """ static const int Cryptography_HAS_ECDH; +static const int Cryptography_HAS_SET_ECDH_AUTO; """ FUNCTIONS = """ @@ -20,6 +21,7 @@ FUNCTIONS = """ MACROS = """ int ECDH_compute_key(void *, size_t, const EC_POINT *, EC_KEY *, void *(*)(const void *, size_t, void *, size_t *)); +int SSL_CTX_set_ecdh_auto(SSL_CTX *, int); """ CUSTOMIZATIONS = """ @@ -33,4 +35,11 @@ int (*ECDH_compute_key)(void *, size_t, const EC_POINT *, EC_KEY *, #else static const long Cryptography_HAS_ECDH = 1; #endif + +#ifndef SSL_CTX_set_ecdh_auto +static const long Cryptography_HAS_SET_ECDH_AUTO = 0; +int (*SSL_CTX_set_ecdh_auto)(SSL_CTX *, int) = NULL; +#else +static const long Cryptography_HAS_SET_ECDH_AUTO = 1; +#endif """ |