auth: Remove USE_BOTH_CRYPT_CALLS block from pass_check.c
authorAndrew Bartlett <abartlet@samba.org>
Wed, 22 Jan 2014 02:57:13 +0000 (15:57 +1300)
committerAndreas Schneider <asn@cryptomilk.org>
Tue, 15 Apr 2014 08:13:12 +0000 (10:13 +0200)
This code is dead since the move to the WAF build system, but was set
for HP-UX 9, 10 and 11 in the autoconf build system.

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
source3/auth/pass_check.c
source4/auth/ntlm/auth_unix.c

index 2941bc07f81d1c6d679e7369367b7ec7e18d93ea..6450559175c88765aac2568ac747355d31c4a816 100644 (file)
@@ -96,25 +96,6 @@ static NTSTATUS password_check(const char *user, const char *password, const voi
 #endif /* ULTRIX_AUTH */
 
 
-#if defined(HAVE_BIGCRYPT) && defined(HAVE_CRYPT) && defined(USE_BOTH_CRYPT_CALLS)
-
-       /*
-        * Some systems have bigcrypt in the C library but might not
-        * actually use it for the password hashes (HPUX 10.20) is
-        * a noteable example. So we try bigcrypt first, followed
-        * by crypt.
-        */
-
-       if (strcmp(bigcrypt(password, get_this_salt()), get_this_crypted()) == 0)
-               return NT_STATUS_OK;
-       else
-               ret = (strcmp((char *)crypt(password, get_this_salt()), get_this_crypted()) == 0);
-       if (ret) {
-               return NT_STATUS_OK;
-       } else {
-               return NT_STATUS_WRONG_PASSWORD;
-       }
-#else /* HAVE_BIGCRYPT && HAVE_CRYPT && USE_BOTH_CRYPT_CALLS */
 
 #ifdef HAVE_BIGCRYPT
        ret = (strcmp(bigcrypt(password, get_this_salt()), get_this_crypted()) == 0);
@@ -136,7 +117,6 @@ static NTSTATUS password_check(const char *user, const char *password, const voi
                return NT_STATUS_WRONG_PASSWORD;
        }
 #endif /* HAVE_CRYPT */
-#endif /* HAVE_BIGCRYPT && HAVE_CRYPT && USE_BOTH_CRYPT_CALLS */
 #endif /* WITH_PAM */
 }
 
index d1f62858eae31c2350d79363052caf6e5ac75774..00abc44f376539b034ba4c63c8cd4b1c65c28c30 100644 (file)
@@ -543,25 +543,6 @@ static NTSTATUS password_check(const char *username, const char *password,
 #endif /* ULTRIX_AUTH */
        
        
-#if defined(HAVE_BIGCRYPT) && defined(HAVE_CRYPT) && defined(USE_BOTH_CRYPT_CALLS)
-       
-       /*
-        * Some systems have bigcrypt in the C library but might not
-        * actually use it for the password hashes (HPUX 10.20) is
-        * a noteable example. So we try bigcrypt first, followed
-        * by crypt.
-        */
-
-       if (strcmp(bigcrypt(password, salt), crypted) == 0)
-               return NT_STATUS_OK;
-       else
-               ret = (strcmp((char *)crypt(password, salt), crypted) == 0);
-       if (ret) {
-               return NT_STATUS_OK;
-       } else {
-               return NT_STATUS_WRONG_PASSWORD;
-       }
-#else /* HAVE_BIGCRYPT && HAVE_CRYPT && USE_BOTH_CRYPT_CALLS */
        
 #ifdef HAVE_BIGCRYPT
        ret = (strcmp(bigcrypt(password, salt), crypted) == 0);
@@ -583,7 +564,6 @@ static NTSTATUS password_check(const char *username, const char *password,
                return NT_STATUS_WRONG_PASSWORD;
        }
 #endif /* HAVE_CRYPT */
-#endif /* HAVE_BIGCRYPT && HAVE_CRYPT && USE_BOTH_CRYPT_CALLS */
 }
 
 static NTSTATUS check_unix_password(TALLOC_CTX *ctx, struct loadparm_context *lp_ctx,