mirror of
https://github.com/proxytunnel/proxytunnel.git
synced 2026-01-23 02:34:59 +00:00
Use OPENSSL_VERSION_NUMBER to compile code matching the applied libssl version.
This renders Makefile.ssl11 redundant.
This commit is contained in:
parent
945f205796
commit
351d2dffc3
3 changed files with 3 additions and 108 deletions
|
|
@ -222,7 +222,7 @@ int check_cert_names(X509 *cert, char *peer_host) {
|
|||
for (i = 0; i < san_count; i++) {
|
||||
gn = sk_GENERAL_NAME_value(gen_names, i);
|
||||
if (gn->type == GEN_DNS && !(peer_host_is_ipv4 || peer_host_is_ipv6)) {
|
||||
#ifdef OPENSSL11
|
||||
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
|
||||
if (check_cert_valid_host((char*)ASN1_STRING_get0_data(gn->d.ia5), peer_host)) {
|
||||
#else
|
||||
if (check_cert_valid_host((char*)ASN1_STRING_data(gn->d.ia5), peer_host)) {
|
||||
|
|
@ -280,7 +280,7 @@ int stream_enable_ssl(PTSTREAM *pts, const char *proxy_arg) {
|
|||
|
||||
/* Initialise the connection */
|
||||
SSLeay_add_ssl_algorithms();
|
||||
#ifdef OPENSSL11
|
||||
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
|
||||
meth = TLS_client_method();
|
||||
#else
|
||||
meth = SSLv23_client_method();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue