]> granicus.if.org Git - curl/commitdiff
sasl: Corrected pre-processor inclusion of SSPI based DIGEST-MD5 code
authorSteve Holme <steve_holme@hotmail.com>
Sun, 6 Apr 2014 11:46:53 +0000 (12:46 +0100)
committerSteve Holme <steve_holme@hotmail.com>
Sun, 6 Apr 2014 12:01:14 +0000 (13:01 +0100)
When CURL_DISABLE_CRYPTO_AUTH is defined the DIGEST-MD5 code should not
be included, regardless of whether USE__WINDOWS_SSPI is defined or not.
This is indicated by the definition of USE_HTTP_NEGOTIATE and USE_NTLM
in curl_setup.h.

lib/curl_sasl.h
lib/curl_sasl_sspi.c

index 6d15c708c39fb72c19f8fc080f10e7e2e33e6107..12f78404cc3fdc302b004f7f78465802f00e62b7 100644 (file)
@@ -76,9 +76,7 @@ CURLcode Curl_sasl_create_cram_md5_message(struct SessionHandle *data,
                                            const char *user,
                                            const char *passwdp,
                                            char **outptr, size_t *outlen);
-#endif
 
-#if !defined(CURL_DISABLE_CRYPTO_AUTH) || defined(USE_WINDOWS_SSPI)
 /* This is used to decode a base64 encoded DIGEST-MD5 challange message */
 CURLcode Curl_sasl_decode_digest_md5_message(const char *chlg64,
                                              char *nonce, size_t nlen,
index e9eaf32300df71bf630e717e983769be75b4aa73..9b67498e9981a6e020bf4525310f261c3efcc841 100644 (file)
@@ -25,7 +25,7 @@
 
 #include "curl_setup.h"
 
-#if defined(USE_WINDOWS_SSPI)
+#if defined(USE_WINDOWS_SSPI) && !defined(CURL_DISABLE_CRYPTO_AUTH)
 
 #include <curl/curl.h>
 
@@ -189,4 +189,4 @@ CURLcode Curl_sasl_create_digest_md5_message(struct SessionHandle *data,
   return result;
 }
 
-#endif /* USE_WINDOWS_SSPI */
+#endif /* USE_WINDOWS_SSPI && !CURL_DISABLE_CRYPTO_AUTH */