directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kayyag...@apache.org
Subject svn commit: r1624052 - /directory/apacheds/trunk/protocol-ldap/src/main/java/org/apache/directory/server/ldap/replication/consumer/ReplicationConsumerImpl.java
Date Wed, 10 Sep 2014 16:10:27 GMT
Author: kayyagari
Date: Wed Sep 10 16:10:26 2014
New Revision: 1624052

URL: http://svn.apache.org/r1624052
Log:
call startTls() after connecting to the server (DIRSERVER-2001)

Modified:
    directory/apacheds/trunk/protocol-ldap/src/main/java/org/apache/directory/server/ldap/replication/consumer/ReplicationConsumerImpl.java

Modified: directory/apacheds/trunk/protocol-ldap/src/main/java/org/apache/directory/server/ldap/replication/consumer/ReplicationConsumerImpl.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/protocol-ldap/src/main/java/org/apache/directory/server/ldap/replication/consumer/ReplicationConsumerImpl.java?rev=1624052&r1=1624051&r2=1624052&view=diff
==============================================================================
--- directory/apacheds/trunk/protocol-ldap/src/main/java/org/apache/directory/server/ldap/replication/consumer/ReplicationConsumerImpl.java
(original)
+++ directory/apacheds/trunk/protocol-ldap/src/main/java/org/apache/directory/server/ldap/replication/consumer/ReplicationConsumerImpl.java
Wed Sep 10 16:10:26 2014
@@ -217,13 +217,12 @@ public class ReplicationConsumerImpl imp
                 connection = new LdapNetworkConnection( providerHost, port );
                 connection.setTimeOut( -1L );
                 connection.setSchemaManager( schemaManager );
-                
+
                 if ( config.isUseTls() )
                 {
                     connection.getConfig().setTrustManagers( config.getTrustManager() );
-                    connection.startTls();
                 }
-
+                
                 connection.addConnectionClosedEventListener( this );
             }
 
@@ -235,6 +234,11 @@ public class ReplicationConsumerImpl imp
                 // Do a bind
                 try
                 {
+                    if ( config.isUseTls() )
+                    {
+                        connection.startTls();
+                    }
+
                     connection.bind( config.getReplUserDn(), Strings.utf8ToString( config.getReplUserPassword()
) );
                     disconnected = false;
 



Mime
View raw message