diff options
-rw-r--r-- | source3/auth/pass_check.c | 8 | ||||
-rw-r--r-- | source3/passdb/pass_check.c | 8 |
2 files changed, 16 insertions, 0 deletions
diff --git a/source3/auth/pass_check.c b/source3/auth/pass_check.c index aea543d853..c803816e04 100644 --- a/source3/auth/pass_check.c +++ b/source3/auth/pass_check.c @@ -134,6 +134,14 @@ static BOOL pam_auth(char *user, char *password) * put a pam_allow.so entry in /etc/pam.conf for account handling. */ pam_error = pam_acct_mgmt(pamh, PAM_SILENT); PAM_BAIL; + + /* + * This will allow samba to aquire a kerberos token. And, when + * exporting an AFS cell, be able to /write/ to this cell. + */ + pam_error = pam_setcred(pamh, (PAM_ESTABLISH_CRED|PAM_SILENT)); + PAM_BAIL; + pam_end(pamh, PAM_SUCCESS); /* If this point is reached, the user has been authenticated. */ return (True); diff --git a/source3/passdb/pass_check.c b/source3/passdb/pass_check.c index aea543d853..c803816e04 100644 --- a/source3/passdb/pass_check.c +++ b/source3/passdb/pass_check.c @@ -134,6 +134,14 @@ static BOOL pam_auth(char *user, char *password) * put a pam_allow.so entry in /etc/pam.conf for account handling. */ pam_error = pam_acct_mgmt(pamh, PAM_SILENT); PAM_BAIL; + + /* + * This will allow samba to aquire a kerberos token. And, when + * exporting an AFS cell, be able to /write/ to this cell. + */ + pam_error = pam_setcred(pamh, (PAM_ESTABLISH_CRED|PAM_SILENT)); + PAM_BAIL; + pam_end(pamh, PAM_SUCCESS); /* If this point is reached, the user has been authenticated. */ return (True); |