Skip to content

Commit

Permalink
Merge pull request #1488 from alex/no-sslv3
Browse files Browse the repository at this point in the history
Support compilation on platforms, such as debian expiremental, which are compiled without SSLv3
  • Loading branch information
reaperhulk committed Nov 24, 2014
2 parents b882426 + 12c9f3a commit 04a3f1f
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/cryptography/hazmat/bindings/openssl/ssl.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
* Internally invented symbols to tell which versions of SSL/TLS are supported.
*/
static const long Cryptography_HAS_SSL2;
static const long Cryptography_HAS_SSL3_METHOD;
static const long Cryptography_HAS_TLSv1_1;
static const long Cryptography_HAS_TLSv1_2;
static const long Cryptography_HAS_SECURE_RENEGOTIATION;
Expand Down Expand Up @@ -384,6 +385,15 @@
static const long Cryptography_HAS_SSL2 = 1;
#endif
#ifdef OPENSSL_NO_SSL3_METHOD
static const long Cryptography_HAS_SSL3_METHOD = 0;
SSL_METHOD* (*SSLv3_method)(void) = NULL;
SSL_METHOD* (*SSLv3_client_method)(void) = NULL;
SSL_METHOD* (*SSLv3_server_method)(void) = NULL;
#else
static const long Cryptography_HAS_SSL3_METHOD = 1;
#endif
#ifdef SSL_CTRL_SET_TLSEXT_HOSTNAME
static const long Cryptography_HAS_TLSEXT_HOSTNAME = 1;
#else
Expand Down Expand Up @@ -554,6 +564,12 @@
"SSLv2_server_method",
],

"Cryptography_HAS_SSL3_METHOD": [
"SSLv3_method",
"SSLv3_client_method",
"SSLv3_server_method",
],

"Cryptography_HAS_TLSEXT_HOSTNAME": [
"SSL_set_tlsext_host_name",
"SSL_get_servername",
Expand Down

0 comments on commit 04a3f1f

Please sign in to comment.