From: W.C.A. Wijngaards Date: Fri, 28 Feb 2020 07:11:11 +0000 (+0100) Subject: Return 0 when ssl authentication is not available X-Git-Tag: release-1.11.0~120^2~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5b61afd38c7dd7a0368a526ab8dab0bf2fb90039;p=thirdparty%2Funbound.git Return 0 when ssl authentication is not available --- diff --git a/util/net_help.c b/util/net_help.c index cc1ca7ec5..2a392781d 100644 --- a/util/net_help.c +++ b/util/net_help.c @@ -1220,14 +1220,14 @@ void* outgoing_ssl_fd(void* sslctx, int fd) int check_auth_name_for_ssl(char* auth_name) { if(!auth_name) return 1; -#ifdef HAVE_SSL -#if !defined(HAVE_SSL_SET1_HOST) && !defined(HAVE_X509_VERIFY_PARAM_SET1_HOST) +#if defined(HAVE_SSL) && !defined(HAVE_SSL_SET1_HOST) && !defined(HAVE_X509_VERIFY_PARAM_SET1_HOST) log_err("the query has an auth_name %s, but libssl has no call to " "perform TLS authentication. Remove that name from config " "or upgrade the ssl crypto library.", auth_name); -#endif -#endif + return 0; +#else return 1; +#endif } /** set the authname on an SSL structure, SSL* ssl */