Get pam_smbpass to compile again (it probably won't link or run, but at least
authorAndrew Bartlett <abartlet@samba.org>
Wed, 30 Apr 2003 13:56:02 +0000 (13:56 +0000)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 30 Apr 2003 13:56:02 +0000 (13:56 +0000)
it compiles and lets the build farm get on it's way)
(This used to be commit 7498d69d9d69f70a4c7511b5032d7d5d2b9c846f)

source3/pam_smbpass/pam_smb_passwd.c
source3/pam_smbpass/support.c

index 8fbef1fbf70ffa8a9b08c6ee82f9e0f61f80fed9..1d022af16c1619c49230100bb0e24b603d365688 100644 (file)
@@ -298,8 +298,8 @@ int pam_sm_chauthtok(pam_handle_t *pamh, int flags,
            uid_t uid;
            
             /* password updated */
-               if (!sid_to_uid(sampass, &uid)) {
-                       _log_err( LOG_NOTICE "Unable to get uid for user %s",
+               if (!sid_to_uid(pdb_get_user_sid(sampass), &uid)) {
+                       _log_err( LOG_NOTICE, "Unable to get uid for user %s",
                                pdb_get_username(sampass));
                        _log_err( LOG_NOTICE, "password for (%s) changed by (%s/%d)",
                                user, uidtoname(getuid()), getuid());
index 61d9c6a8aba97ae2a1033b4fed278723fc502ff1..d3232237ac2716702c3670e47a297524116b47e4 100644 (file)
@@ -308,7 +308,6 @@ void _cleanup_failures( pam_handle_t * pamh, void *fl, int err )
 int _smb_verify_password( pam_handle_t * pamh, SAM_ACCOUNT *sampass,
                          const char *p, unsigned int ctrl )
 {
-    uchar hash_pass[16];
     uchar lm_pw[16];
     uchar nt_pw[16];
     int retval = PAM_AUTH_ERR;
@@ -375,7 +374,6 @@ int _smb_verify_password( pam_handle_t * pamh, SAM_ACCOUNT *sampass,
         pam_get_item( pamh, PAM_SERVICE, (const void **)&service );
 
         if (data_name != NULL) {
-           int type;
             struct _pam_failed_auth *new = NULL;
             const struct _pam_failed_auth *old = NULL;
 
@@ -401,7 +399,7 @@ int _smb_verify_password( pam_handle_t * pamh, SAM_ACCOUNT *sampass,
                       service ? service : "**unknown**", name);
                     new->count = 1;
                 }
-               if (!sid_to_uid(pdb_get_user_sid(sampass, &(new->id), &type))) {
+               if (!sid_to_uid(pdb_get_user_sid(sampass), &(new->id))) {
                     _log_err(LOG_NOTICE,
                       "failed auth request by %s for service %s as %s",
                       uidtoname(getuid()),