https://issues.apache.org/bugzilla/show_bug.cgi?id=54587
Bug ID: 54587
Summary: LDAPConnectionPoolTimeout does not work in all cases
Product: Apache httpd-2
Version: 2.5-HEAD
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P2
Component: mod_ldap
Assignee: [email protected]
Reporter: [email protected]
Classification: Unclassified
I got a report from a user that LDAPConnectionPoolTimeout does not work. It
seems removing this check for l->bound fixes his problem:
--- a/modules/ldap/util_ldap.c
+++ b/modules/ldap/util_ldap.c
@@ -715,7 +715,7 @@ static util_ldap_connection_t *
&& !compare_client_certs(dc->client_certs, l->client_certs))
{
if (st->connection_pool_ttl > 0) {
- if (l->bound && (now - l->freed) > st->connection_pool_ttl) {
+ if ((now - l->freed) > st->connection_pool_ttl) {
ap_log_rerror(APLOG_MARK, APLOG_TRACE1, 0, r,
"Removing LDAP connection last used %"
APR_TIME_T_FMT " seconds ago",
(now - l->freed) / APR_USEC_PER_SEC);
Briefly looking through the code, I think this resetting of l->bound may be the
cause of the problem:
/*
* We have just bound the connection to a different user and password
* combination, which might be reused unintentionally next time this
* connection is used from the connection pool. To ensure no confusion,
* we mark the connection as unbound.
*/
ldc->bound = 0;
I haven't looked deeply enough to tell what would be the correct fix.
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]