security/proxytunnel: Fix all SSL configuration, fix no SSLv3 (LibreSSL)

Approved by:	SSL blanket
This commit is contained in:
John Marino 2016-09-13 18:09:33 +00:00
parent f710e90d77
commit a17f4f530c
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=422051
2 changed files with 30 additions and 0 deletions

View File

@ -0,0 +1,16 @@
--- Makefile.orig 2012-01-23 18:13:41 UTC
+++ Makefile
@@ -46,9 +46,11 @@ OPTFLAGS += -DSO_REUSEPORT
# END system dependant block
-SSL_LIBS := $(shell pkg-config --libs libssl 2>/dev/null)
-ifeq ($(SSL_LIBS),)
SSL_LIBS := $(shell pkg-config --libs openssl 2>/dev/null)
+CFLAGS += $(shell pkg-config --cflags openssl 2>/dev/null)
+ifeq ($(SSL_LIBS),)
+SSL_LIBS := $(shell pkg-config --libs libssl 2>/dev/null)
+CFLAGS += $(shell pkg-config --cflags libssl 2>/dev/null)
endif
ifeq ($(SSL_LIBS),)
SSL_LIBS := -lssl -lcrypto

View File

@ -0,0 +1,14 @@
--- ptstream.c.orig 2012-01-23 18:13:41 UTC
+++ ptstream.c
@@ -151,7 +151,11 @@ int stream_enable_ssl(PTSTREAM *pts) {
/* Initialise the connection */
SSLeay_add_ssl_algorithms();
+#ifndef OPENSSL_NO_SSL3
meth = SSLv3_client_method();
+#else
+ meth = SSLv23_client_method();
+#endif
SSL_load_error_strings();
ctx = SSL_CTX_new (meth);