Author: alessio.soldano(a)jboss.com
Date: 2013-04-26 13:09:58 -0400 (Fri, 26 Apr 2013)
New Revision: 17517
Modified:
stack/cxf/branches/jbossws-cxf-3.1.2/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wssePolicy/SignEncryptGCMTestCase.java
stack/cxf/branches/jbossws-cxf-3.1.2/pom.xml
Log:
[JBPAPP-10708] Adding a testcase and moving to latest cxf
Modified:
stack/cxf/branches/jbossws-cxf-3.1.2/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wssePolicy/SignEncryptGCMTestCase.java
===================================================================
---
stack/cxf/branches/jbossws-cxf-3.1.2/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wssePolicy/SignEncryptGCMTestCase.java 2013-04-26
17:07:26 UTC (rev 17516)
+++
stack/cxf/branches/jbossws-cxf-3.1.2/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wssePolicy/SignEncryptGCMTestCase.java 2013-04-26
17:09:58 UTC (rev 17517)
@@ -66,6 +66,25 @@
}
}
+ public void testCVE20125575() throws Exception
+ {
+ QName serviceName = new
QName("http://www.jboss.org/jbossws/ws-extensions/wssecuritypolicy",
"SecurityService");
+ URL wsdlURL =
getResourceURL("jaxws/samples/wssePolicy/sign-encrypt/WEB-INF/wsdl/SecurityService.wsdl");
+ Service service = Service.create(wsdlURL, serviceName);
+ ServiceIface proxy = (ServiceIface)service.getPort(ServiceIface.class);
+
((BindingProvider)proxy).getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY,
serviceURL);
+ setupWsse(proxy);
+ try
+ {
+ proxy.sayHello();
+ fail("Exception expected!");
+ }
+ catch (SOAPFaultException e)
+ {
+ assertTrue(e.getMessage().contains("An error was discovered processing the
<wsse:Security> header"));
+ }
+ }
+
private void setupWsse(ServiceIface proxy)
{
((BindingProvider)proxy).getRequestContext().put(SecurityConstants.CALLBACK_HANDLER, new
KeystorePasswordCallback());
Modified: stack/cxf/branches/jbossws-cxf-3.1.2/pom.xml
===================================================================
--- stack/cxf/branches/jbossws-cxf-3.1.2/pom.xml 2013-04-26 17:07:26 UTC (rev 17516)
+++ stack/cxf/branches/jbossws-cxf-3.1.2/pom.xml 2013-04-26 17:09:58 UTC (rev 17517)
@@ -53,7 +53,7 @@
<jbossws.jboss510.version>3.1.0-SNAPSHOT</jbossws.jboss510.version>
-->
<!-- END -->
- <cxf.version>2.2.12-patch-06-SNAPSHOT</cxf.version>
+ <cxf.version>2.2.12-patch-07-SNAPSHOT</cxf.version>
<cxf.spring.version>2.5.6.SEC02</cxf.spring.version>
<cxf.stax.version>1.0.1</cxf.stax.version>
<cxf.asm.version>3.1</cxf.asm.version>