diff options
author | Arthur de Jong <arthur@arthurdejong.org> | 2010-12-12 22:24:29 +0000 |
---|---|---|
committer | Arthur de Jong <arthur@arthurdejong.org> | 2010-12-12 22:24:29 +0000 |
commit | 9b07d97c4c4b64d70b54473344b8f858794c9221 (patch) | |
tree | b1a4c044ed890cde5ffbecf4162b9cbc87aab00d | |
parent | f13d4d573a3cb241080434b1ded5b66fa91a4eec (diff) |
always return a positive authorisation result during authentication because we don't do any authorisation checks during authentication and this may confuse the PAM module if it's only used for authorisation
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1327 ef36b2f9-881f-0410-afb5-c4e39611909c
-rw-r--r-- | nslcd/pam.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/nslcd/pam.c b/nslcd/pam.c index fca0d53..f6d3877 100644 --- a/nslcd/pam.c +++ b/nslcd/pam.c @@ -192,9 +192,9 @@ int nslcd_pam_authc(TFILE *fp,MYLDAP_SESSION *session,uid_t calleruid) WRITE_INT32(fp,NSLCD_RESULT_BEGIN); WRITE_STRING(fp,username); WRITE_STRING(fp,""); - WRITE_INT32(fp,NSLCD_PAM_AUTHINFO_UNAVAIL); /* authc */ - WRITE_INT32(fp,NSLCD_PAM_AUTHINFO_UNAVAIL); /* authz */ - WRITE_STRING(fp,"LDAP server unavaiable"); /* authzmsg */ + WRITE_INT32(fp,NSLCD_PAM_AUTHINFO_UNAVAIL); /* authc */ + WRITE_INT32(fp,NSLCD_PAM_SUCCESS); /* authz */ + WRITE_STRING(fp,"LDAP server unavaiable"); /* authzmsg */ } WRITE_INT32(fp,NSLCD_RESULT_END); return -1; @@ -214,9 +214,9 @@ int nslcd_pam_authc(TFILE *fp,MYLDAP_SESSION *session,uid_t calleruid) WRITE_INT32(fp,NSLCD_RESULT_BEGIN); WRITE_STRING(fp,username); WRITE_STRING(fp,userdn); - WRITE_INT32(fp,rc); /* authc */ - WRITE_INT32(fp,rc); /* authz */ - WRITE_STRING(fp,""); /* authzmsg */ + WRITE_INT32(fp,rc); /* authc */ + WRITE_INT32(fp,NSLCD_PAM_SUCCESS); /* authz */ + WRITE_STRING(fp,""); /* authzmsg */ WRITE_INT32(fp,NSLCD_RESULT_END); return 0; } |