From 1ac2df0ef25760cedfd9794fd0660032878f18d8 Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Mon, 25 Feb 2019 10:55:16 +0800 Subject: [PATCH 1/5] remove NPN bindings -- you should be using ALPN! pyOpenSSL consumed these, but we've marked it as deprecated and it already handles the case where the bindings are not available. --- src/_cffi_src/openssl/ssl.py | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/_cffi_src/openssl/ssl.py b/src/_cffi_src/openssl/ssl.py index 4ba8669307ea..804e49c2efc0 100644 --- a/src/_cffi_src/openssl/ssl.py +++ b/src/_cffi_src/openssl/ssl.py @@ -440,25 +440,9 @@ long SSL_session_reused(SSL *); -void SSL_CTX_set_next_protos_advertised_cb(SSL_CTX *, - int (*)(SSL *, - const unsigned char **, - unsigned int *, - void *), - void *); -void SSL_CTX_set_next_proto_select_cb(SSL_CTX *, - int (*)(SSL *, - unsigned char **, - unsigned char *, - const unsigned char *, - unsigned int, - void *), - void *); int SSL_select_next_proto(unsigned char **, unsigned char *, const unsigned char *, unsigned int, const unsigned char *, unsigned int); -void SSL_get0_next_proto_negotiated(const SSL *, - const unsigned char **, unsigned *); int sk_SSL_CIPHER_num(Cryptography_STACK_OF_SSL_CIPHER *); const SSL_CIPHER *sk_SSL_CIPHER_value(Cryptography_STACK_OF_SSL_CIPHER *, int); From e92d9c59fa4bfcd0e3489591bd400a84254e30e8 Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Mon, 25 Feb 2019 11:05:46 +0800 Subject: [PATCH 2/5] set Cryptography_HAS_NEXTPROTONEG to 0 for pyOpenSSL we can remove this symbol in like...5 years. --- src/_cffi_src/openssl/ssl.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/_cffi_src/openssl/ssl.py b/src/_cffi_src/openssl/ssl.py index 804e49c2efc0..954faadf93e2 100644 --- a/src/_cffi_src/openssl/ssl.py +++ b/src/_cffi_src/openssl/ssl.py @@ -649,7 +649,7 @@ static const long Cryptography_HAS_SSL_OP_MSIE_SSLV2_RSA_PADDING = 1; static const long Cryptography_HAS_SSL_OP_NO_TICKET = 1; static const long Cryptography_HAS_SSL_SET_SSL_CTX = 1; -static const long Cryptography_HAS_NEXTPROTONEG = 1; +static const long Cryptography_HAS_NEXTPROTONEG = 0; static const long Cryptography_HAS_ALPN = 1; #if CRYPTOGRAPHY_IS_LIBRESSL From e1777f434281a3d259752b6aa263a9120d160dc9 Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Mon, 25 Feb 2019 11:12:10 +0800 Subject: [PATCH 3/5] remove another NPN related definition --- src/_cffi_src/openssl/ssl.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/_cffi_src/openssl/ssl.py b/src/_cffi_src/openssl/ssl.py index 954faadf93e2..a00a0595bddc 100644 --- a/src/_cffi_src/openssl/ssl.py +++ b/src/_cffi_src/openssl/ssl.py @@ -139,8 +139,6 @@ static const long TLS_ST_BEFORE; static const long TLS_ST_OK; -static const long OPENSSL_NPN_NEGOTIATED; - typedef ... SSL_METHOD; typedef ... SSL_CTX; From 1f256baef22a489b04ed50f5e8fdd01b30ae50dc Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Sun, 19 May 2019 20:17:47 -0400 Subject: [PATCH 4/5] suspicious --- .travis/downstream.d/twisted.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis/downstream.d/twisted.sh b/.travis/downstream.d/twisted.sh index 3d45413bbe21..034ec790b5f7 100755 --- a/.travis/downstream.d/twisted.sh +++ b/.travis/downstream.d/twisted.sh @@ -9,7 +9,7 @@ case "${1}" in ;; run) cd twisted - python -m twisted.trial src/twisted + python -m twisted.trial twisted.protocols.test.test_tls.TLSMemoryBIOTests.test_disorderlyShutdown ;; *) exit 1 From c1352fc05e764f854aa57c6de7c9d611eab3b932 Mon Sep 17 00:00:00 2001 From: Paul Kehrer Date: Mon, 9 Sep 2019 08:03:22 +0800 Subject: [PATCH 5/5] Revert "remove another NPN related definition" This reverts commit d872a7d1d776858c77b8c607f63cc9b5fef1ae39. Revert "suspicious" This reverts commit 5b767484f1cde132f686600a46e61a18e33cbdae. --- .travis/downstream.d/twisted.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis/downstream.d/twisted.sh b/.travis/downstream.d/twisted.sh index 034ec790b5f7..3d45413bbe21 100755 --- a/.travis/downstream.d/twisted.sh +++ b/.travis/downstream.d/twisted.sh @@ -9,7 +9,7 @@ case "${1}" in ;; run) cd twisted - python -m twisted.trial twisted.protocols.test.test_tls.TLSMemoryBIOTests.test_disorderlyShutdown + python -m twisted.trial src/twisted ;; *) exit 1