From b6821dbb91a7433d7451c1ad4cbd49cc4b8a71a9 Mon Sep 17 00:00:00 2001 From: Steve Holme Date: Sun, 2 Nov 2014 00:24:32 +0000 Subject: sasl: Fixed Kerberos V5 inclusion when CURL_DISABLE_CRYPTO_AUTH is used Typically the USE_WINDOWS_SSPI definition would not be used when the CURL_DISABLE_CRYPTO_AUTH define is, however, it is still a valid build configuration and, as such, the SASL Kerberos V5 (GSSAPI) authentication data structures and functions would incorrectly be used when they shouldn't be. Introduced a new USE_KRB5 definition that takes into account the use of CURL_DISABLE_CRYPTO_AUTH like USE_SPNEGO and USE_NTLM do. --- lib/curl_setup.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'lib/curl_setup.h') diff --git a/lib/curl_setup.h b/lib/curl_setup.h index 353b15fcb..a20aab19b 100644 --- a/lib/curl_setup.h +++ b/lib/curl_setup.h @@ -608,12 +608,18 @@ int netware_init(void); #define USE_SSL /* SSL support has been enabled */ #endif +/* Single point where USE_SPNEGO definition might be defined */ #if !defined(CURL_DISABLE_CRYPTO_AUTH) && \ (defined(HAVE_GSSAPI) || defined(USE_WINDOWS_SSPI)) #define USE_SPNEGO #endif -/* Single point where USE_NTLM definition might be done */ +/* Single point where USE_KRB5 definition might be defined */ +#if !defined(CURL_DISABLE_CRYPTO_AUTH) && defined(USE_WINDOWS_SSPI) +#define USE_KRB5 +#endif + +/* Single point where USE_NTLM definition might be defined */ #if !defined(CURL_DISABLE_HTTP) && !defined(CURL_DISABLE_NTLM) && \ !defined(CURL_DISABLE_CRYPTO_AUTH) #if defined(USE_SSLEAY) || defined(USE_WINDOWS_SSPI) || \ -- cgit v1.2.3