summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2010-08-18 18:23:49 +0200
committerVolker Lendecke <vl@samba.org>2010-08-22 22:42:21 +0200
commit177e394f93278407557702d9f53bae65fd5fc434 (patch)
tree86e740e30d4bfb10adeae52a78b9bd0002ada984 /source3/smbd
parent265f0b7745b811d6ba1575eb277213f707215a3b (diff)
downloadsamba-177e394f93278407557702d9f53bae65fd5fc434.tar.gz
samba-177e394f93278407557702d9f53bae65fd5fc434.tar.bz2
samba-177e394f93278407557702d9f53bae65fd5fc434.zip
s3: Pass the rhost through smb_pam_accountcheck
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/sesssetup.c2
-rw-r--r--source3/smbd/smb2_sesssetup.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/source3/smbd/sesssetup.c b/source3/smbd/sesssetup.c
index a476ed42ae..9ff5d55133 100644
--- a/source3/smbd/sesssetup.c
+++ b/source3/smbd/sesssetup.c
@@ -427,7 +427,7 @@ static void reply_spnego_kerberos(struct smb_request *req,
/* if a real user check pam account restrictions */
/* only really perfomed if "obey pam restriction" is true */
/* do this before an eventual mapping to guest occurs */
- ret = smb_pam_accountcheck(pw->pw_name);
+ ret = smb_pam_accountcheck(pw->pw_name, sconn->client_id.name);
if ( !NT_STATUS_IS_OK(ret)) {
DEBUG(1,("PAM account restriction "
"prevents user login\n"));
diff --git a/source3/smbd/smb2_sesssetup.c b/source3/smbd/smb2_sesssetup.c
index df00b4f654..4a91e845fc 100644
--- a/source3/smbd/smb2_sesssetup.c
+++ b/source3/smbd/smb2_sesssetup.c
@@ -294,7 +294,8 @@ static NTSTATUS smbd_smb2_session_setup_krb5(struct smbd_smb2_session *session,
/* if a real user check pam account restrictions */
/* only really perfomed if "obey pam restriction" is true */
/* do this before an eventual mapping to guest occurs */
- status = smb_pam_accountcheck(pw->pw_name);
+ status = smb_pam_accountcheck(
+ pw->pw_name, smb2req->sconn->client_id.name);
if (!NT_STATUS_IS_OK(status)) {
DEBUG(1,("smb2: PAM account restriction "
"prevents user login\n"));