directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kayyag...@apache.org
Subject svn commit: r1559772 - /directory/shared/trunk/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
Date Mon, 20 Jan 2014 16:35:23 GMT
Author: kayyagari
Date: Mon Jan 20 16:35:23 2014
New Revision: 1559772

URL: http://svn.apache.org/r1559772
Log:
prevent establishing startTLS if the session is already using TLS (DIRAPI-173) 

Modified:
    directory/shared/trunk/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java

Modified: directory/shared/trunk/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
URL: http://svn.apache.org/viewvc/directory/shared/trunk/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java?rev=1559772&r1=1559771&r2=1559772&view=diff
==============================================================================
--- directory/shared/trunk/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
(original)
+++ directory/shared/trunk/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
Mon Jan 20 16:35:23 2014
@@ -3695,6 +3695,13 @@ public class LdapNetworkConnection exten
 
             checkSession();
 
+            IoFilter sslFilter = ldapSession.getFilterChain().get( SSL_FILTER_KEY );
+            if ( sslFilter != null )
+            {
+               LOG.debug( "LDAP session already using startTLS" );
+               return;
+            }
+            
             ExtendedResponse resp = extended( START_TLS_REQ_OID );
             LdapResult result = resp.getLdapResult();
 



Mime
View raw message