cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1492327 - in /cxf/branches/2.7.x-fixes: rt/transports/http-hc/src/main/java/org/apache/cxf/transport/http/asyncclient/AsyncHTTPConduit.java systests/transports/src/test/java/org/apache/cxf/systest/http/HTTPSClientTest.java
Date Wed, 12 Jun 2013 18:26:09 GMT
Author: dkulp
Date: Wed Jun 12 18:26:00 2013
New Revision: 1492327

URL: http://svn.apache.org/r1492327
Log:
Merged revisions 1492319 via  git cherry-pick from
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1492319 | dkulp | 2013-06-12 14:13:55 -0400 (Wed, 12 Jun 2013) | 2 lines

  [CXF-5063] Make sure the keymanagers are not wrapped within the TLSClientParams to avoid
hash changes and cause major problems

........

Modified:
    cxf/branches/2.7.x-fixes/rt/transports/http-hc/src/main/java/org/apache/cxf/transport/http/asyncclient/AsyncHTTPConduit.java
    cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/HTTPSClientTest.java

Modified: cxf/branches/2.7.x-fixes/rt/transports/http-hc/src/main/java/org/apache/cxf/transport/http/asyncclient/AsyncHTTPConduit.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/rt/transports/http-hc/src/main/java/org/apache/cxf/transport/http/asyncclient/AsyncHTTPConduit.java?rev=1492327&r1=1492326&r2=1492327&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/rt/transports/http-hc/src/main/java/org/apache/cxf/transport/http/asyncclient/AsyncHTTPConduit.java
(original)
+++ cxf/branches/2.7.x-fixes/rt/transports/http-hc/src/main/java/org/apache/cxf/transport/http/asyncclient/AsyncHTTPConduit.java
Wed Jun 12 18:26:00 2013
@@ -809,20 +809,25 @@ public class AsyncHTTPConduit extends UR
         sslengine.setEnabledCipherSuites(cipherSuites);
     }
 
-    protected static void getKeyManagersWithCertAlias(TLSClientParameters tlsClientParameters,
+    protected static KeyManager[] getKeyManagersWithCertAlias(TLSClientParameters tlsClientParameters,
                                                       KeyManager[] keyManagers) throws GeneralSecurityException
{
         if (tlsClientParameters.getCertAlias() != null) {
+            KeyManager ret[] = new KeyManager[keyManagers.length];  
             for (int idx = 0; idx < keyManagers.length; idx++) {
                 if (keyManagers[idx] instanceof X509KeyManager) {
                     try {
-                        keyManagers[idx] = new AliasedX509ExtendedKeyManager(tlsClientParameters.getCertAlias(),
+                        ret[idx] = new AliasedX509ExtendedKeyManager(tlsClientParameters.getCertAlias(),
                                                                              (X509KeyManager)keyManagers[idx]);
                     } catch (Exception e) {
                         throw new GeneralSecurityException(e);
                     }
+                } else {
+                    ret[idx] = keyManagers[idx]; 
                 }
             }
+            return ret;
         }
+        return keyManagers;
     }
 
 

Modified: cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/HTTPSClientTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/HTTPSClientTest.java?rev=1492327&r1=1492326&r2=1492327&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/HTTPSClientTest.java
(original)
+++ cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/HTTPSClientTest.java
Wed Jun 12 18:26:00 2013
@@ -128,7 +128,10 @@ public class HTTPSClientTest extends Abs
               BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
               address);
         
+        //provider.getRequestContext().put("use.async.http.conduit", Boolean.TRUE);
+        //for (int x = 0; x < 100000; x++) {
         assertEquals(port.greetMe("Kitty"), "Hello Kitty");
+        //}
         
         
         stopServers();



Mime
View raw message