You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by bn...@apache.org on 2004/11/04 16:46:51 UTC
cvs commit: httpd-2.0/modules/ldap util_ldap.c
bnicholes 2004/11/04 07:46:51
Modified: modules/ldap util_ldap.c
Log:
If the entry has a password then don't allow util_ldap_cache_getuserdn() to update the expiration timeout since it has no idea when the password was last validated.
Submitted by: Jari Ahonen [jah progress.com]
Revision Changes Path
1.19 +6 -1 httpd-2.0/modules/ldap/util_ldap.c
Index: util_ldap.c
===================================================================
RCS file: /home/cvs/httpd-2.0/modules/ldap/util_ldap.c,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- util_ldap.c 1 Nov 2004 23:43:24 -0000 1.18
+++ util_ldap.c 4 Nov 2004 15:46:51 -0000 1.19
@@ -1096,7 +1096,12 @@
/* Nothing in cache, insert new entry */
util_ald_cache_insert(curl->search_cache, &the_search_node);
}
- else {
+ /*
+ * Don't update lastbind on entries with bindpw because
+ * we haven't verified that password. It's OK to update
+ * the entry if there is no password in it.
+ */
+ else if (!search_nodep->bindpw) {
/* Cache entry is valid, update lastbind */
search_nodep->lastbind = the_search_node.lastbind;
}