You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by or...@apache.org on 2019/03/06 17:05:46 UTC

[qpid-jms-amqp-0-x] branch master updated: QPID-8281: [JMS AMQP 0-x] Sync client test keystores with broker-j test keystores

This is an automated email from the ASF dual-hosted git repository.

orudyy pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/qpid-jms-amqp-0-x.git


The following commit(s) were added to refs/heads/master by this push:
     new 8abff1b  QPID-8281: [JMS AMQP 0-x] Sync client test keystores with broker-j test keystores
8abff1b is described below

commit 8abff1b7c232fb3f7e8f64d4446ea4decb1e22ae
Author: Alex Rudyy <or...@apache.org>
AuthorDate: Wed Mar 6 14:52:06 2019 +0000

    QPID-8281: [JMS AMQP 0-x] Sync client test keystores with broker-j test keystores
---
 .../java/org/apache/qpid/ssl/TrustManagerTest.java    |   2 +-
 client/src/test/resources/java_broker_peerstore.jks   | Bin 802 -> 1162 bytes
 client/src/test/resources/java_broker_truststore.jks  | Bin 591 -> 1082 bytes
 client/src/test/resources/java_client_keystore.jks    | Bin 5786 -> 7641 bytes
 client/src/test/resources/java_client_truststore.jks  | Bin 591 -> 1082 bytes
 .../test/resources/java_client_untrusted_keystore.jks | Bin 2056 -> 2467 bytes
 systests/src/main/resources/tls/broker_peerstore.jks  | Bin 802 -> 1162 bytes
 systests/src/main/resources/tls/client_keystore.jks   | Bin 5786 -> 7641 bytes
 .../extension/encryption/MessageEncryptionTest.java   |   8 ++++++++
 9 files changed, 9 insertions(+), 1 deletion(-)

diff --git a/client/src/test/java/org/apache/qpid/ssl/TrustManagerTest.java b/client/src/test/java/org/apache/qpid/ssl/TrustManagerTest.java
index 3fdfb33..b3cb62d 100644
--- a/client/src/test/java/org/apache/qpid/ssl/TrustManagerTest.java
+++ b/client/src/test/java/org/apache/qpid/ssl/TrustManagerTest.java
@@ -38,7 +38,7 @@ import org.apache.qpid.transport.network.security.ssl.SSLUtil;
 
 public class TrustManagerTest extends QpidTestCase
 {
-    private static final String STORE_TYPE = "JKS";
+    private static final String STORE_TYPE = "PKCS12";
     private static final String DEFAULT_TRUST_MANAGER_ALGORITHM = TrustManagerFactory.getDefaultAlgorithm();
 
     // retrieves the client certificate's chain from store and returns it as an array
diff --git a/client/src/test/resources/java_broker_peerstore.jks b/client/src/test/resources/java_broker_peerstore.jks
index 69cdd40..a5b307f 100644
Binary files a/client/src/test/resources/java_broker_peerstore.jks and b/client/src/test/resources/java_broker_peerstore.jks differ
diff --git a/client/src/test/resources/java_broker_truststore.jks b/client/src/test/resources/java_broker_truststore.jks
index e6d556a..4184adf 100644
Binary files a/client/src/test/resources/java_broker_truststore.jks and b/client/src/test/resources/java_broker_truststore.jks differ
diff --git a/client/src/test/resources/java_client_keystore.jks b/client/src/test/resources/java_client_keystore.jks
index 941fc7e..9422d9a 100644
Binary files a/client/src/test/resources/java_client_keystore.jks and b/client/src/test/resources/java_client_keystore.jks differ
diff --git a/client/src/test/resources/java_client_truststore.jks b/client/src/test/resources/java_client_truststore.jks
index ab79b54..1b45a23 100644
Binary files a/client/src/test/resources/java_client_truststore.jks and b/client/src/test/resources/java_client_truststore.jks differ
diff --git a/client/src/test/resources/java_client_untrusted_keystore.jks b/client/src/test/resources/java_client_untrusted_keystore.jks
index 45a0c10..8b0b023 100644
Binary files a/client/src/test/resources/java_client_untrusted_keystore.jks and b/client/src/test/resources/java_client_untrusted_keystore.jks differ
diff --git a/systests/src/main/resources/tls/broker_peerstore.jks b/systests/src/main/resources/tls/broker_peerstore.jks
index 69cdd40..a5b307f 100644
Binary files a/systests/src/main/resources/tls/broker_peerstore.jks and b/systests/src/main/resources/tls/broker_peerstore.jks differ
diff --git a/systests/src/main/resources/tls/client_keystore.jks b/systests/src/main/resources/tls/client_keystore.jks
index 941fc7e..9422d9a 100644
Binary files a/systests/src/main/resources/tls/client_keystore.jks and b/systests/src/main/resources/tls/client_keystore.jks differ
diff --git a/systests/src/test/java/org/apache/qpid/systest/extension/encryption/MessageEncryptionTest.java b/systests/src/test/java/org/apache/qpid/systest/extension/encryption/MessageEncryptionTest.java
index 6a81c1a..daca8f8 100644
--- a/systests/src/test/java/org/apache/qpid/systest/extension/encryption/MessageEncryptionTest.java
+++ b/systests/src/test/java/org/apache/qpid/systest/extension/encryption/MessageEncryptionTest.java
@@ -100,11 +100,18 @@ public class MessageEncryptionTest extends JmsTestBase
         {
             Files.copy(in, _trustStore, REPLACE_EXISTING);
         }
+        // QPID-8283: Setting password with JVM setting due to client defect
+        System.setProperty("javax.net.ssl.trustStorePassword", STORE_PASSWORD);
+        System.setProperty("javax.net.ssl.trustStoreType", "pkcs12");
+        System.setProperty("javax.net.ssl.keyStoreType", "pkcs12");
     }
 
     @After
     public void tearDown()
     {
+        System.clearProperty("javax.net.ssl.trustStorePassword");
+        System.clearProperty("javax.net.ssl.trustStoreType");
+        System.clearProperty("javax.net.ssl.keyStoreType");
         if (_trustStore != null)
         {
             _trustStore.toFile().delete();
@@ -497,6 +504,7 @@ public class MessageEncryptionTest extends JmsTestBase
         peerStoreAttributes.put("type", "FileTrustStore");
         peerStoreAttributes.put("qpid-type", "FileTrustStore");
         peerStoreAttributes.put("exposedAsMessageSource", true);
+        peerStoreAttributes.put("trustStoreType", "pkcs12");
         peerStoreAttributes.putAll(additionalAttributes);
 
         createEntity(peerStoreName, "org.apache.qpid.server.security.FileTrustStore", peerStoreAttributes);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org