summaryrefslogtreecommitdiff
path: root/ldap/apr_ldap_option.c
diff options
context:
space:
mode:
authorbnicholes <bnicholes@13f79535-47bb-0310-9956-ffa450edef68>2005-01-10 19:05:18 +0000
committerbnicholes <bnicholes@13f79535-47bb-0310-9956-ffa450edef68>2005-01-10 19:05:18 +0000
commit829fd0084e6a39093fa9e969ce4b6150f75d3ad7 (patch)
treebd884be5456856a5680521a5afc6aef860c1436e /ldap/apr_ldap_option.c
parenta625f11460bcc75b754bc1aac77e3c036c1f4229 (diff)
downloadlibapr-util-829fd0084e6a39093fa9e969ce4b6150f75d3ad7.tar.gz
Remove the call to ldapssl_install_routines for the Novell SDK. Do to the warning that states that if any other ldap call is made between the calls to ldap_init() and ldapssl_install_routines(), it is safer for the Novell SDK to always initialize the connection using ldapssl_init(). Suggest that other SDKs do the same.
git-svn-id: http://svn.apache.org/repos/asf/apr/apr-util/trunk@124824 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'ldap/apr_ldap_option.c')
-rw-r--r--ldap/apr_ldap_option.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/ldap/apr_ldap_option.c b/ldap/apr_ldap_option.c
index 293181b0..789dc1c1 100644
--- a/ldap/apr_ldap_option.c
+++ b/ldap/apr_ldap_option.c
@@ -164,7 +164,7 @@ int option_set_tls(apr_pool_t *pool,
#endif
/* Novell SDK */
-#if APR_HAS_NOVELL_SDK
+#if APR_HAS_NOVELL_LDAPSDK
/* ldapssl_install_routines(ldap)
* Behavior is unpredictable when other LDAP functions are called
* between the ldap_init function and the ldapssl_install_routines
@@ -172,15 +172,15 @@ int option_set_tls(apr_pool_t *pool,
*
* STARTTLS is supported by the ldap_start_tls_s() method
*/
- if (APR_LDAP_SSL == tls) {
+ /*if ((APR_LDAP_SSL == tls) || (APR_LDAP_STARTTLS == tls)) {
result->rc = ldapssl_install_routines(ldap);
if (result->rc != LDAP_SUCCESS) {
result->msg = ldap_err2string(result->rc);
result->reason = "LDAP: Could not switch SSL on for this "
"connection.";
}
- }
- else if (APR_LDAP_STARTTLS == tls) {
+ }*/
+ if (APR_LDAP_STARTTLS == tls) {
result->rc = ldapssl_start_tls(ldap);
if (result->rc != LDAP_SUCCESS) {
result->msg = ldap_err2string(result->rc);
@@ -415,28 +415,28 @@ int option_set_cert(apr_pool_t *pool,
case APR_LDAP_CERT_TYPE_DER: {
result->rc = ldapssl_set_client_cert((void *)cert->path,
LDAPSSL_CERT_FILETYPE_DER,
- cert->password);
+ (void*)cert->password);
result->msg = ldap_err2string(result->rc);
break;
}
case APR_LDAP_CERT_TYPE_BASE64: {
result->rc = ldapssl_set_client_cert((void *)cert->path,
LDAPSSL_CERT_FILETYPE_B64,
- cert->password);
+ (void*)cert->password);
result->msg = ldap_err2string(result->rc);
break;
}
case APR_LDAP_KEY_TYPE_DER: {
result->rc = ldapssl_set_client_private_key((void *)cert->path,
LDAPSSL_CERT_FILETYPE_DER,
- cert->password);
+ (void*)cert->password);
result->msg = ldap_err2string(result->rc);
break;
}
case APR_LDAP_KEY_TYPE_BASE64: {
result->rc = ldapssl_set_client_private_key((void *)cert->path,
LDAPSSL_CERT_FILETYPE_B64,
- cert->password);
+ (void*)cert->password);
result->msg = ldap_err2string(result->rc);
break;
}