You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by mi...@apache.org on 2005/01/20 09:15:47 UTC
svn commit: r125733 - /httpd/httpd/trunk/modules/ldap/util_ldap.c
Author: minfrin
Date: Thu Jan 20 00:15:46 2005
New Revision: 125733
URL: http://svn.apache.org/viewcvs?view=rev&rev=125733
Log:
Fix a problem where SSL was started twice when no client certificates were
specified.
Modified:
httpd/httpd/trunk/modules/ldap/util_ldap.c
Modified: httpd/httpd/trunk/modules/ldap/util_ldap.c
Url: http://svn.apache.org/viewcvs/httpd/httpd/trunk/modules/ldap/util_ldap.c?view=diff&rev=125733&p1=httpd/httpd/trunk/modules/ldap/util_ldap.c&r1=125732&p2=httpd/httpd/trunk/modules/ldap/util_ldap.c&r2=125733
==============================================================================
--- httpd/httpd/trunk/modules/ldap/util_ldap.c (original)
+++ httpd/httpd/trunk/modules/ldap/util_ldap.c Thu Jan 20 00:15:46 2005
@@ -310,14 +310,17 @@
}
/* switch on SSL/TLS */
- apr_ldap_set_option(ldc->pool, ldc->ldap,
- APR_LDAP_OPT_TLS, &ldc->secure, &(result));
- if (LDAP_SUCCESS != result->rc) {
- ldap_unbind_s(ldc->ldap);
- ldc->ldap = NULL;
- ldc->bound = 0;
- ldc->reason = result->reason;
- return(result->rc);
+ if (!apr_is_empty_array(ldc->client_certs)) {
+
+ apr_ldap_set_option(ldc->pool, ldc->ldap,
+ APR_LDAP_OPT_TLS, &ldc->secure, &(result));
+ if (LDAP_SUCCESS != result->rc) {
+ ldap_unbind_s(ldc->ldap);
+ ldc->ldap = NULL;
+ ldc->bound = 0;
+ ldc->reason = result->reason;
+ return(result->rc);
+ }
}
/* Set the alias dereferencing option */