From commits-return-6502-apmail-apr-commits-archive=apr.apache.org@apr.apache.org Fri Jan 21 14:09:50 2005 Return-Path: Delivered-To: apmail-apr-commits-archive@www.apache.org Received: (qmail 36325 invoked from network); 21 Jan 2005 14:09:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 21 Jan 2005 14:09:50 -0000 Received: (qmail 84298 invoked by uid 500); 21 Jan 2005 14:09:49 -0000 Delivered-To: apmail-apr-commits-archive@apr.apache.org Received: (qmail 84267 invoked by uid 500); 21 Jan 2005 14:09:49 -0000 Mailing-List: contact commits-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: dev@apr.apache.org Delivered-To: mailing list commits@apr.apache.org Received: (qmail 84248 invoked by uid 99); 21 Jan 2005 14:09:48 -0000 X-ASF-Spam-Status: No, hits=-9.8 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from minotaur.apache.org (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.28) with SMTP; Fri, 21 Jan 2005 06:09:48 -0800 Received: (qmail 36289 invoked by uid 65534); 21 Jan 2005 14:09:47 -0000 Date: 21 Jan 2005 14:09:47 -0000 Message-ID: <20050121140947.36283.qmail@minotaur.apache.org> From: minfrin@apache.org To: commits@apr.apache.org Subject: svn commit: r125930 - /apr/apr-util/branches/1.1.x/include/apr_ldap.h.in /apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Author: minfrin Date: Fri Jan 21 06:09:46 2005 New Revision: 125930 URL: http://svn.apache.org/viewcvs?view=rev&rev=125930 Log: Solaris v2.9's LDAP is a repackaged Netscape/Mozilla SDK. Detect and handle it correctly. Modified: apr/apr-util/branches/1.1.x/include/apr_ldap.h.in apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c Modified: apr/apr-util/branches/1.1.x/include/apr_ldap.h.in Url: http://svn.apache.org/viewcvs/apr/apr-util/branches/1.1.x/include/apr_ldap.h.in?view=diff&rev=125930&p1=apr/apr-util/branches/1.1.x/include/apr_ldap.h.in&r1=125929&p2=apr/apr-util/branches/1.1.x/include/apr_ldap.h.in&r2=125930 ============================================================================== --- apr/apr-util/branches/1.1.x/include/apr_ldap.h.in (original) +++ apr/apr-util/branches/1.1.x/include/apr_ldap.h.in Fri Jan 21 06:09:46 2005 @@ -77,7 +77,6 @@ #define APR_HAS_LDAP_SSLINIT @apu_has_ldap_sslinit@ #define APR_HAS_LDAPSSL_INIT @apu_has_ldapssl_init@ - /* * Make sure the secure LDAP port is defined */ Modified: apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c Url: http://svn.apache.org/viewcvs/apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c?view=diff&rev=125930&p1=apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c&r1=125929&p2=apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c&r2=125930 ============================================================================== --- apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c (original) +++ apr/apr-util/branches/1.1.x/ldap/apr_ldap_option.c Fri Jan 21 06:09:46 2005 @@ -140,8 +140,9 @@ #if APR_HAS_LDAP_SSL /* compiled with ssl support */ - /* Netscape SDK */ -#if APR_HAS_NETSCAPE_LDAPSDK + /* Netscape/Mozilla/Solaris SDK */ +#if APR_HAS_NETSCAPE_LDAPSDK || APR_HAS_SOLARIS_LDAPSDK +#ifdef LDAP_OPT_SSL if (tls == APR_LDAP_SSL) { result->rc = ldapssl_install_routines(ldap); if (result->rc == LDAP_SUCCESS) { @@ -155,15 +156,22 @@ } else if (tls == APR_LDAP_STARTTLS) { result->reason = "LDAP: STARTTLS is not supported by the " - "Netscape/Mozilla SDK"; + "Netscape/Mozilla/Solaris SDK"; result->rc = -1; } else if (tls == APR_LDAP_STOPTLS) { result->reason = "LDAP: STOPTLS is not supported by the " - "Netscape/Mozilla SDK"; + "Netscape/Mozilla/Solaris SDK"; + result->rc = -1; + } +#else + if (tls != APR_LDAP_NONE) { + result->reason = "LDAP: SSL/TLS is not supported by this version " + "of the Netscape/Mozilla/Solaris SDK"; result->rc = -1; } #endif +#endif /* Novell SDK */ #if APR_HAS_NOVELL_LDAPSDK @@ -224,20 +232,13 @@ result->rc = -1; } #else - result->reason = "LDAP: SSL/TLS not yet supported by APR on this " - "version of the OpenLDAP toolkit"; - result->rc = -1; -#endif -#endif - - /* Solaris SDK */ -#if APR_HAS_SOLARIS_LDAPSDK if (tls != APR_LDAP_NONE) { - result->reason = "LDAP: SSL/TLS is currently not supported by " - "APR on the Solaris SDK"; + result->reason = "LDAP: SSL/TLS not yet supported by APR on this " + "version of the OpenLDAP toolkit"; result->rc = -1; } #endif +#endif /* Microsoft SDK */ #if APR_HAS_MICROSOFT_LDAPSDK @@ -307,8 +308,9 @@ #if APR_HAS_LDAP_SSL -#if APR_HAS_NETSCAPE_LDAPSDK -#if APR_HAS_LDAP_SSL_CLIENT_INIT + /* Netscape/Mozilla/Solaris SDK */ +#if APR_HAS_NETSCAPE_LDAPSDK || APR_HAS_SOLARIS_LDAPSDK +#if APR_HAS_LDAPSSL_CLIENT_INIT const char *nickname = NULL; const char *secmod = NULL; const char *key3db = NULL; @@ -381,9 +383,9 @@ } } #else - result->reason = "LDAP: ldapssl_client_init() function not " - "supported by this Netscape SDK. Certificate " - "authority file not set"; + result->reason = "LDAP: SSL/TLS ldapssl_client_init() function not " + "supported by this Netscape/Mozilla/Solaris SDK. " + "Certificate authority file not set"; result->rc = -1; #endif #endif @@ -525,14 +527,6 @@ * here with a message explaining this. */ result->reason = "LDAP: CA certificates cannot be set using this method, " "as they are stored in the registry instead."; - result->rc = -1; -#endif - - /* Sun SDK */ -#if APR_HAS_SOLARIS_LDAPSDK - result->reason = "LDAP: Attempt to set certificate store failed. " - "APR does not yet know how to set a certificate " - "store on the Sun toolkit"; result->rc = -1; #endif