summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2001-05-01 17:19:42 +0000
committerJeremy Allison <jra@samba.org>2001-05-01 17:19:42 +0000
commit5197ccfef498d8d8072fba71d3bd58509fa10ad4 (patch)
tree90d50bf47f908f8ba7bf8ec73222b2f2c168bb49
parent089d8c544fb694cc38de5a1dac3e78022b7c835a (diff)
downloadsamba-5197ccfef498d8d8072fba71d3bd58509fa10ad4.tar.gz
samba-5197ccfef498d8d8072fba71d3bd58509fa10ad4.tar.bz2
samba-5197ccfef498d8d8072fba71d3bd58509fa10ad4.zip
Added Andrew Bartlett's fixes to my changes to his original patch (at the
court of king caractacus, was just passing by... :-). Jeremy. (This used to be commit acc3e7a057ad7fb0c2fb1cafff0c623ec0524d04)
-rw-r--r--source3/auth/pampass.c4
-rw-r--r--source3/auth/pass_check.c2
-rw-r--r--source3/passdb/pampass.c4
-rw-r--r--source3/passdb/pass_check.c2
4 files changed, 6 insertions, 6 deletions
diff --git a/source3/auth/pampass.c b/source3/auth/pampass.c
index 09b84db71a..061e5ee0bf 100644
--- a/source3/auth/pampass.c
+++ b/source3/auth/pampass.c
@@ -664,9 +664,9 @@ uint32 smb_pam_passcheck(char * user, char * password)
*/
if ((pconv = smb_setup_pam_conv(smb_pam_conv, user, password, NULL)) == NULL)
- return False;
+ return NT_STATUS_LOGON_FAILURE;
- if (!smb_pam_start(&pamh, user, NULL, NULL))
+ if (!smb_pam_start(&pamh, user, NULL, pconv))
return NT_STATUS_LOGON_FAILURE;
if ((nt_status = smb_pam_auth(pamh, user)) != NT_STATUS_NOPROBLEMO) {
diff --git a/source3/auth/pass_check.c b/source3/auth/pass_check.c
index 05f7138c3c..9424189b23 100644
--- a/source3/auth/pass_check.c
+++ b/source3/auth/pass_check.c
@@ -599,7 +599,7 @@ static BOOL password_check(char *password)
{
#ifdef WITH_PAM
- return (smb_pam_passcheck(this_user, password));
+ return (smb_pam_passcheck(this_user, password) == NT_STATUS_NOPROBLEMO);
#endif /* WITH_PAM */
#ifdef WITH_AFS
diff --git a/source3/passdb/pampass.c b/source3/passdb/pampass.c
index 09b84db71a..061e5ee0bf 100644
--- a/source3/passdb/pampass.c
+++ b/source3/passdb/pampass.c
@@ -664,9 +664,9 @@ uint32 smb_pam_passcheck(char * user, char * password)
*/
if ((pconv = smb_setup_pam_conv(smb_pam_conv, user, password, NULL)) == NULL)
- return False;
+ return NT_STATUS_LOGON_FAILURE;
- if (!smb_pam_start(&pamh, user, NULL, NULL))
+ if (!smb_pam_start(&pamh, user, NULL, pconv))
return NT_STATUS_LOGON_FAILURE;
if ((nt_status = smb_pam_auth(pamh, user)) != NT_STATUS_NOPROBLEMO) {
diff --git a/source3/passdb/pass_check.c b/source3/passdb/pass_check.c
index 05f7138c3c..9424189b23 100644
--- a/source3/passdb/pass_check.c
+++ b/source3/passdb/pass_check.c
@@ -599,7 +599,7 @@ static BOOL password_check(char *password)
{
#ifdef WITH_PAM
- return (smb_pam_passcheck(this_user, password));
+ return (smb_pam_passcheck(this_user, password) == NT_STATUS_NOPROBLEMO);
#endif /* WITH_PAM */
#ifdef WITH_AFS