From 5cf5a2a3b7af2a604b099cc0c64772bc1ddce982 Mon Sep 17 00:00:00 2001 From: Matthias Andree Date: Fri, 6 Sep 2019 18:16:53 +0000 Subject: Fix a sed regexp from GNUism to POSIX. Thanks! Also sent upstream for inclusion today, https://sourceforge.net/p/openvpn/mailman/message/36757480/ and https://sourceforge.net/p/openvpn/mailman/message/36757481/ PR: 240306 Submitted by: kevans@ --- security/openvpn/files/patch-configure | 4 ++-- security/openvpn/files/patch-libressl | 20 -------------------- .../files/patch-src_openvpn_openssl__compat.h | 20 ++++++++++++++++++++ security/openvpn/files/patch-tests_t__lpback.sh | 11 +++++++++++ 4 files changed, 33 insertions(+), 22 deletions(-) delete mode 100644 security/openvpn/files/patch-libressl create mode 100644 security/openvpn/files/patch-src_openvpn_openssl__compat.h create mode 100644 security/openvpn/files/patch-tests_t__lpback.sh (limited to 'security/openvpn/files') diff --git a/security/openvpn/files/patch-configure b/security/openvpn/files/patch-configure index 226436314279..ad89145fa80c 100644 --- a/security/openvpn/files/patch-configure +++ b/security/openvpn/files/patch-configure @@ -1,6 +1,6 @@ ---- configure.orig 2016-08-23 14:19:07 UTC +--- configure.orig 2019-02-20 12:28:34 UTC +++ configure -@@ -17160,8 +17160,6 @@ fi +@@ -18120,8 +18120,6 @@ fi $as_echo "!! WARNING !! The cmoka git submodule has not been initialized or updated. Unit testing cannot be performed." >&6; } fi else diff --git a/security/openvpn/files/patch-libressl b/security/openvpn/files/patch-libressl deleted file mode 100644 index 8b139124328a..000000000000 --- a/security/openvpn/files/patch-libressl +++ /dev/null @@ -1,20 +0,0 @@ ---- ./src/openvpn/openssl_compat.h 2018-03-01 07:22:19.000000000 +0000 -+++ ./src/openvpn/openssl_compat.h 2018-03-12 10:44:08.876010487 +0000 -@@ -711,7 +711,7 @@ - } - #endif /* SSL_CTX_get_max_proto_version */ - --#ifndef SSL_CTX_set_min_proto_version -+#if !defined(SSL_CTX_set_min_proto_version) && !defined(LIBRESSL_VERSION_NUMBER) - /** Mimics SSL_CTX_set_min_proto_version for OpenSSL < 1.1 */ - static inline int - SSL_CTX_set_min_proto_version(SSL_CTX *ctx, long tls_ver_min) -@@ -740,7 +740,7 @@ - } - #endif /* SSL_CTX_set_min_proto_version */ - --#ifndef SSL_CTX_set_max_proto_version -+#if !defined(SSL_CTX_set_max_proto_version) && !defined(LIBRESSL_VERSION_NUMBER) - /** Mimics SSL_CTX_set_max_proto_version for OpenSSL < 1.1 */ - static inline int - SSL_CTX_set_max_proto_version(SSL_CTX *ctx, long tls_ver_max) diff --git a/security/openvpn/files/patch-src_openvpn_openssl__compat.h b/security/openvpn/files/patch-src_openvpn_openssl__compat.h new file mode 100644 index 000000000000..4f72e79ef421 --- /dev/null +++ b/security/openvpn/files/patch-src_openvpn_openssl__compat.h @@ -0,0 +1,20 @@ +--- src/openvpn/openssl_compat.h.orig 2019-02-20 12:28:23 UTC ++++ src/openvpn/openssl_compat.h +@@ -735,7 +735,7 @@ SSL_CTX_get_max_proto_version(SSL_CTX *ctx) + } + #endif /* SSL_CTX_get_max_proto_version */ + +-#ifndef SSL_CTX_set_min_proto_version ++#if !defined(SSL_CTX_set_min_proto_version) && !defined(LIBRESSL_VERSION_NUMBER) + /** Mimics SSL_CTX_set_min_proto_version for OpenSSL < 1.1 */ + static inline int + SSL_CTX_set_min_proto_version(SSL_CTX *ctx, long tls_ver_min) +@@ -764,7 +764,7 @@ SSL_CTX_set_min_proto_version(SSL_CTX *ctx, long tls_v + } + #endif /* SSL_CTX_set_min_proto_version */ + +-#ifndef SSL_CTX_set_max_proto_version ++#if !defined(SSL_CTX_set_max_proto_version) && !defined(LIBRESSL_VERSION_NUMBER) + /** Mimics SSL_CTX_set_max_proto_version for OpenSSL < 1.1 */ + static inline int + SSL_CTX_set_max_proto_version(SSL_CTX *ctx, long tls_ver_max) diff --git a/security/openvpn/files/patch-tests_t__lpback.sh b/security/openvpn/files/patch-tests_t__lpback.sh new file mode 100644 index 000000000000..c92fb42135f3 --- /dev/null +++ b/security/openvpn/files/patch-tests_t__lpback.sh @@ -0,0 +1,11 @@ +--- tests/t_lpback.sh.orig 2019-09-03 13:22:50 UTC ++++ tests/t_lpback.sh +@@ -26,7 +26,7 @@ trap "rm -f key.$$ tc-server-key.$$ tc-client-key.$$ l + + # Get list of supported ciphers from openvpn --show-ciphers output + CIPHERS=$(${top_builddir}/src/openvpn/openvpn --show-ciphers | \ +- sed -e '/The following/,/^$/d' -e s'/ .*//' -e '/^\s*$/d') ++ sed -e '/The following/,/^$/d' -e s'/ .*//' -e '/^[[:space:]]*$/d') + + # SK, 2014-06-04: currently the DES-EDE3-CFB1 implementation of OpenSSL is + # broken (see http://rt.openssl.org/Ticket/Display.html?id=2867), so exclude -- cgit v1.2.3