lists.arthurdejong.org
RSS feed

nss-pam-ldapd commit: r1327 - nss-pam-ldapd/nslcd

[Date Prev][Date Next] [Thread Prev][Thread Next]

nss-pam-ldapd commit: r1327 - nss-pam-ldapd/nslcd



Author: arthur
Date: Sun Dec 12 23:24:29 2010
New Revision: 1327
URL: http://arthurdejong.org/viewvc/nss-pam-ldapd?view=rev&revision=1327

Log:
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

Modified:
   nss-pam-ldapd/nslcd/pam.c

Modified: nss-pam-ldapd/nslcd/pam.c
==============================================================================
--- nss-pam-ldapd/nslcd/pam.c   Sun Dec 12 23:22:28 2010        (r1326)
+++ nss-pam-ldapd/nslcd/pam.c   Sun Dec 12 23:24:29 2010        (r1327)
@@ -192,9 +192,9 @@
       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 @@
   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;
 }
--
To unsubscribe send an email to
nss-pam-ldapd-commits-unsubscribe@lists.arthurdejong.org or see
http://lists.arthurdejong.org/nss-pam-ldapd-commits