Skip to content

Commit

Permalink
smb: Build with SSPI enabled
Browse files Browse the repository at this point in the history
Build SMB/CIFS protocol support when SSPI is enabled.
  • Loading branch information
Bill Nagel authored and captain-caveman2k committed Dec 7, 2014
1 parent eb88d77 commit 526603f
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 12 deletions.
5 changes: 3 additions & 2 deletions configure.ac
Expand Up @@ -3494,8 +3494,9 @@ if test "x$CURL_DISABLE_IMAP" != "x1"; then
fi
if test "x$CURL_DISABLE_SMB" != "x1" \
-a "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" \
-a \( "x$USE_SSLEAY" = "x1" -o "x$GNUTLS_ENABLED" = "x1" \
-o "x$NSS_ENABLED" = "x1" -o "x$DARWINSSL_ENABLED" = "x1" \); then
-a \( "x$USE_SSLEAY" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \
-o "x$GNUTLS_ENABLED" = "x1" -o "x$NSS_ENABLED" = "x1" \
-o "x$DARWINSSL_ENABLED" = "x1" \); then
SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMB"
if test "x$SSL_ENABLED" = "x1"; then
SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMBS"
Expand Down
5 changes: 2 additions & 3 deletions lib/smb.c
Expand Up @@ -22,8 +22,7 @@

#include "curl_setup.h"

#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
!defined(USE_WINDOWS_SSPI)
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM)

#define BUILDING_CURL_SMB_C

Expand Down Expand Up @@ -895,4 +894,4 @@ static CURLcode smb_parse_url_path(struct connectdata *conn)
return CURLE_OK;
}

#endif /* CURL_DISABLE_SMB && USE_NTLM && USE_WINDOWS_SSPI */
#endif /* CURL_DISABLE_SMB && USE_NTLM */
5 changes: 2 additions & 3 deletions lib/smb.h
Expand Up @@ -256,12 +256,11 @@ struct smb_tree_disconnect {

#endif /* BUILDING_CURL_SMB_C */

#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
!defined(USE_WINDOWS_SSPI)
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM)

extern const struct Curl_handler Curl_handler_smb;
extern const struct Curl_handler Curl_handler_smbs;

#endif /* CURL_DISABLE_SMB && USE_NTLM && USE_WINDOWS_SSPI */
#endif /* CURL_DISABLE_SMB && USE_NTLM */

#endif /* HEADER_CURL_SMB_H */
3 changes: 1 addition & 2 deletions lib/url.c
Expand Up @@ -220,8 +220,7 @@ static const struct Curl_handler * const protocols[] = {
#endif
#endif

#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
!defined(USE_WINDOWS_SSPI)
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM)
&Curl_handler_smb,
#ifdef USE_SSL
&Curl_handler_smbs,
Expand Down
3 changes: 1 addition & 2 deletions lib/version.c
Expand Up @@ -216,8 +216,7 @@ static const char * const protocols[] = {
#ifdef USE_LIBSSH2
"sftp",
#endif
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM) && \
!defined(USE_WINDOWS_SSPI)
#if !defined(CURL_DISABLE_SMB) && defined(USE_NTLM)
"smb",
# ifdef USE_SSL
"smbs",
Expand Down

0 comments on commit 526603f

Please sign in to comment.