Return-Path: X-Original-To: apmail-cxf-commits-archive@www.apache.org Delivered-To: apmail-cxf-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AD43110C13 for ; Thu, 22 Jan 2015 12:12:31 +0000 (UTC) Received: (qmail 29494 invoked by uid 500); 22 Jan 2015 12:12:31 -0000 Delivered-To: apmail-cxf-commits-archive@cxf.apache.org Received: (qmail 29434 invoked by uid 500); 22 Jan 2015 12:12:31 -0000 Mailing-List: contact commits-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list commits@cxf.apache.org Received: (qmail 29424 invoked by uid 99); 22 Jan 2015 12:12:31 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Jan 2015 12:12:31 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 08B0BE0398; Thu, 22 Jan 2015 12:12:30 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: coheigea@apache.org To: commits@cxf.apache.org Date: Thu, 22 Jan 2015 12:12:31 -0000 Message-Id: <1d36510d6d3249a5aefbe6b865ccc520@git.apache.org> In-Reply-To: <4b8aa4fee12940f19fc592428eba3e2e@git.apache.org> References: <4b8aa4fee12940f19fc592428eba3e2e@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [2/2] cxf git commit: Adding a new test Adding a new test Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/2b1e50d3 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/2b1e50d3 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/2b1e50d3 Branch: refs/heads/master Commit: 2b1e50d3192a1cb318f19c97cd69ccd44c477d7a Parents: e980daa Author: Colm O hEigeartaigh Authored: Thu Jan 22 10:56:01 2015 +0000 Committer: Colm O hEigeartaigh Committed: Thu Jan 22 12:12:25 2015 +0000 ---------------------------------------------------------------------- .../cxf/systest/ws/x509/X509TokenTest.java | 27 ++++++ .../systest/ws/x509/DoubleItX509Signature.wsdl | 93 +++++++++++++++++++- .../org/apache/cxf/systest/ws/x509/client.xml | 8 ++ .../org/apache/cxf/systest/ws/x509/server.xml | 7 ++ .../apache/cxf/systest/ws/x509/stax-server.xml | 8 ++ 5 files changed, 142 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cxf/blob/2b1e50d3/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/x509/X509TokenTest.java ---------------------------------------------------------------------- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/x509/X509TokenTest.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/x509/X509TokenTest.java index ae4ab7f..a376a2b 100644 --- a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/x509/X509TokenTest.java +++ b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/x509/X509TokenTest.java @@ -1091,6 +1091,33 @@ public class X509TokenTest extends AbstractBusClientServerTestBase { } @org.junit.Test + public void testAsymmetricSignatureEncryption() throws Exception { + + SpringBusFactory bf = new SpringBusFactory(); + URL busFile = X509TokenTest.class.getResource("client.xml"); + + Bus bus = bf.createBus(busFile.toString()); + SpringBusFactory.setDefaultBus(bus); + SpringBusFactory.setThreadDefaultBus(bus); + + URL wsdl = X509TokenTest.class.getResource("DoubleItX509Signature.wsdl"); + Service service = Service.create(wsdl, SERVICE_QNAME); + QName portQName = new QName(NAMESPACE, "DoubleItAsymmetricSignatureEncryptionPort"); + DoubleItPortType x509Port = + service.getPort(portQName, DoubleItPortType.class); + updateAddressPort(x509Port, test.getPort()); + + if (test.isStreaming()) { + SecurityTestUtil.enableStreaming(x509Port); + } + + x509Port.doubleIt(25); + + ((java.io.Closeable)x509Port).close(); + bus.shutdown(true); + } + + @org.junit.Test public void testAsymmetricSignatureReplay() throws Exception { if (test.isStreaming()) { return; http://git-wip-us.apache.org/repos/asf/cxf/blob/2b1e50d3/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/DoubleItX509Signature.wsdl ---------------------------------------------------------------------- diff --git a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/DoubleItX509Signature.wsdl b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/DoubleItX509Signature.wsdl index 79d280c..6f094fd 100644 --- a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/DoubleItX509Signature.wsdl +++ b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/DoubleItX509Signature.wsdl @@ -73,6 +73,24 @@ + + + + + + + + + + + + + + + + + + @@ -101,6 +119,9 @@ + + + @@ -174,7 +195,7 @@ - + Signature_Encryption_Policy @@ -226,6 +247,64 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -294,4 +373,16 @@ + + + + + + + + + + + + http://git-wip-us.apache.org/repos/asf/cxf/blob/2b1e50d3/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/client.xml ---------------------------------------------------------------------- diff --git a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/client.xml b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/client.xml index 072090d..be02dbb 100644 --- a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/client.xml +++ b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/client.xml @@ -211,6 +211,14 @@ + + + + + + + + http://git-wip-us.apache.org/repos/asf/cxf/blob/2b1e50d3/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/server.xml ---------------------------------------------------------------------- diff --git a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/server.xml b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/server.xml index 055a600..61c5519 100644 --- a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/server.xml +++ b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/server.xml @@ -214,6 +214,13 @@ + + + + + + + http://git-wip-us.apache.org/repos/asf/cxf/blob/2b1e50d3/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/stax-server.xml ---------------------------------------------------------------------- diff --git a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/stax-server.xml b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/stax-server.xml index a4ac402..d57fda6 100644 --- a/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/stax-server.xml +++ b/systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/x509/stax-server.xml @@ -237,6 +237,14 @@ + + + + + + + +