cxf git commit: [CXF-6178] Make everything about netty completely optional.
Repository: cxf Updated Branches: refs/heads/master 3c47717aa - 4f54343fc [CXF-6178] Make everything about netty completely optional. Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/4f54343f Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/4f54343f Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/4f54343f Branch: refs/heads/master Commit: 4f54343fc281f4b918158a5bf22538c95717 Parents: 3c47717 Author: Daniel Kulp dk...@apache.org Authored: Fri Jan 23 11:45:04 2015 -0500 Committer: Daniel Kulp dk...@apache.org Committed: Fri Jan 23 11:45:04 2015 -0500 -- .../src/main/resources/META-INF/cxf/bus-extensions.txt | 2 +- .../src/main/resources/META-INF/cxf/bus-extensions.txt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/4f54343f/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt -- diff --git a/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt b/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt index b63a389..9e62cc6 100644 --- a/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt +++ b/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt @@ -1,2 +1,2 @@ -org.apache.cxf.transport.http.netty.client.NettyHttpTransportFactory::true +org.apache.cxf.transport.http.netty.client.NettyHttpTransportFactory::true:true org.apache.cxf.transport.http.netty.client.NettyHttpConduitFactory::true:true http://git-wip-us.apache.org/repos/asf/cxf/blob/4f54343f/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt -- diff --git a/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt b/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt index d7f4cbb..5006ab2 100644 --- a/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt +++ b/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt @@ -1,3 +1,3 @@ -org.apache.cxf.transport.http.netty.server.NettyHttpTransportFactory::true +org.apache.cxf.transport.http.netty.server.NettyHttpTransportFactory::true:true org.apache.cxf.transport.http.netty.server.NettyHttpDestinationFactory::true:true -org.apache.cxf.transport.http.netty.server.NettyHttpServerEngineFactory::true +org.apache.cxf.transport.http.netty.server.NettyHttpServerEngineFactory::true:true
cxf git commit: CXF-6187 Adding jndiURL
Repository: cxf Updated Branches: refs/heads/master 4f54343fc - 9a0203052 CXF-6187 Adding jndiURL Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/9a020305 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/9a020305 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/9a020305 Branch: refs/heads/master Commit: 9a02030525326802cd117a487eceb82d693092b0 Parents: 4f54343 Author: Christian Schneider ch...@die-schneider.net Authored: Fri Jan 23 18:12:47 2015 +0100 Committer: Christian Schneider ch...@die-schneider.net Committed: Fri Jan 23 18:12:47 2015 +0100 -- .../src/main/java/demo/client/ClientJMS.java| 3 +- .../src/main/java/demo/server/ServerJMS.java| 43 2 files changed, 27 insertions(+), 19 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/9a020305/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/client/ClientJMS.java -- diff --git a/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/client/ClientJMS.java b/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/client/ClientJMS.java index 43ecb89..86b16b9 100644 --- a/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/client/ClientJMS.java +++ b/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/client/ClientJMS.java @@ -30,7 +30,8 @@ import demo.service.HelloWorld; public final class ClientJMS { private static final String JMS_ENDPOINT_URI = jms:queue:test.cxf.jmstransport.queue?timeToLive=1000 + jndiConnectionFactoryName=ConnectionFactory + jndiInitialContextFactory - + =org.apache.activemq.jndi.ActiveMQInitialContextFactory; + + =org.apache.activemq.jndi.ActiveMQInitialContextFactory + + jndiURL=tcp://localhost:61616; private static final QName SERVICE_QNAME = new QName(http://impl.service.demo/;, HelloWorldImplService); http://git-wip-us.apache.org/repos/asf/cxf/blob/9a020305/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/server/ServerJMS.java -- diff --git a/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/server/ServerJMS.java b/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/server/ServerJMS.java index 6d03861..8da3b9f 100644 --- a/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/server/ServerJMS.java +++ b/distribution/src/main/release/samples/java_first_jms/src/main/java/demo/server/ServerJMS.java @@ -19,6 +19,7 @@ package demo.server; +import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import javax.xml.ws.Endpoint; @@ -34,7 +35,8 @@ public final class ServerJMS { private static final String JMS_ENDPOINT_URI = jms:queue:test.cxf.jmstransport.queue?timeToLive=1000 + jndiConnectionFactoryName=ConnectionFactory + jndiInitialContextFactory - + =org.apache.activemq.jndi.ActiveMQInitialContextFactory; + + =org.apache.activemq.jndi.ActiveMQInitialContextFactory + + jndiURL=tcp://localhost:61616; private ServerJMS() { // @@ -55,23 +57,7 @@ public final class ServerJMS { } if (launchAmqBroker) { -/* - * The following make it easier to run this against something other than ActiveMQ. You will have - * to get a JMS broker onto the right port of localhost. - */ -Class? brokerClass = ServerJMS.class.getClassLoader() -.loadClass(org.apache.activemq.broker.BrokerService); -if (brokerClass == null) { -System.err.println(ActiveMQ is not in the classpath, cannot launch broker.); -return; -} -Object broker = brokerClass.newInstance(); -Method addConnectorMethod = brokerClass.getMethod(addConnector, String.class); -addConnectorMethod.invoke(broker, tcp://localhost:61616); -Method setDataDirectory = brokerClass.getMethod(setDataDirectory, String.class); -setDataDirectory.invoke(broker, target/activemq-data); -Method startMethod = brokerClass.getMethod(start); -startMethod.invoke(broker); +launchAMQBroker(); } if (jaxws) { @@ -86,6 +72,27 @@ public final class ServerJMS { System.exit(0); } +private static
cxf git commit: Adding some modified request testing for WS-Security
Repository: cxf Updated Branches: refs/heads/3.0.x-fixes be929cdcb - c748748b4 Adding some modified request testing for WS-Security Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/c748748b Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/c748748b Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/c748748b Branch: refs/heads/3.0.x-fixes Commit: c748748b4064e341653aa60aaacde8e770c9aefb Parents: be929cd Author: Colm O hEigeartaigh cohei...@apache.org Authored: Fri Jan 23 16:34:53 2015 + Committer: Colm O hEigeartaigh cohei...@apache.org Committed: Fri Jan 23 16:35:47 2015 + -- .../ws/common/KeystorePasswordCallback.java | 1 + .../fault/AbstractModifyRequestInterceptor.java | 102 ++ .../systest/ws/fault/ModifiedRequestServer.java | 47 +++ .../systest/ws/fault/ModifiedRequestTest.java | 335 +++ .../cxf/systest/ws/fault/DoubleItFault.wsdl | 63 .../cxf/systest/ws/fault/client-untrusted.xml | 37 ++ .../org/apache/cxf/systest/ws/fault/client.xml | 10 + .../cxf/systest/ws/fault/modified-server.xml| 38 +++ 8 files changed, 633 insertions(+) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/c748748b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java -- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java index aad0518..511155a 100644 --- a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java +++ b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java @@ -45,6 +45,7 @@ public class KeystorePasswordCallback implements CallbackHandler { passwords.put(abcd, dcba); passwords.put(6e0e88f36ebb8744d470f62f604d03ea4ebe5094, password); passwords.put(wss40rev, security); +passwords.put(morpit, password); } /** http://git-wip-us.apache.org/repos/asf/cxf/blob/c748748b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java -- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java new file mode 100644 index 000..53432e9 --- /dev/null +++ b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java @@ -0,0 +1,102 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.cxf.systest.ws.fault; + +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Iterator; +import java.util.Set; + +import javax.xml.namespace.QName; +import javax.xml.soap.SOAPException; +import javax.xml.soap.SOAPHeaderElement; +import javax.xml.soap.SOAPMessage; + +import org.w3c.dom.Element; + +import org.apache.cxf.binding.soap.SoapMessage; +import org.apache.cxf.binding.soap.saaj.SAAJUtils; +import org.apache.cxf.interceptor.Fault; +import org.apache.cxf.message.Message; +import org.apache.cxf.phase.Phase; +import org.apache.cxf.phase.PhaseInterceptor; +import org.apache.cxf.ws.security.wss4j.PolicyBasedWSS4JOutInterceptor; +import org.apache.wss4j.dom.WSConstants; + +public abstract class AbstractModifyRequestInterceptor implements PhaseInterceptorSoapMessage { + +private static final QName SEC_HEADER = +new QName(WSConstants.WSSE_NS, WSConstants.WSSE_LN, WSConstants.WSSE_PREFIX); +private SetString afterInterceptors = new HashSetString(); + +public AbstractModifyRequestInterceptor() { +getAfter().add(PolicyBasedWSS4JOutInterceptor.class.getName()); +} + +public void
[1/2] cxf git commit: Recording .gitmergeinfo Changes
Repository: cxf Updated Branches: refs/heads/2.7.x-fixes 3589f95c2 - 07aad7b5a Recording .gitmergeinfo Changes Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/07aad7b5 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/07aad7b5 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/07aad7b5 Branch: refs/heads/2.7.x-fixes Commit: 07aad7b5ae93119bd3fafff04fd4f23e949ae79b Parents: 5f5be21 Author: Daniel Kulp dk...@apache.org Authored: Fri Jan 23 12:55:22 2015 -0500 Committer: Daniel Kulp dk...@apache.org Committed: Fri Jan 23 12:55:22 2015 -0500 -- .gitmergeinfo | 13 + 1 file changed, 13 insertions(+) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/07aad7b5/.gitmergeinfo -- diff --git a/.gitmergeinfo b/.gitmergeinfo index 0e60d95..d5fec2a 100644 --- a/.gitmergeinfo +++ b/.gitmergeinfo @@ -216,6 +216,7 @@ B 1d7d2a30452d2323ef7c262c88254d1c38b305c9 B 1d884dc801901c2f343582651fc5aca05d81f24a B 1ddf740976e130c838bc7e6a012048765eda3ee0 B 1df23fc6b70d95f9fd5b47697cd8ffacb5f45c50 +B 1e11ca8324d765dd4a8d2c82a3d814f70a68926c B 1e4a285f03eb40c5b2941012120e65ed698e99c7 B 1e7e0eeeafa5453bfe12b24ae072044a136341ac B 1e8aba05df7f3b9a7b9b486a107a534d35e8d81a @@ -436,6 +437,7 @@ B 3c07e4ad86e7a43c493ec8c6559884adc67fded4 B 3c4055e82b9d3b2e55c5554811bf7622c1447956 B 3c424913fcaa01fe8a07580281f86995247942ea B 3c5d07049883ddabcf7101ae6f5ac9c19d12937d +B 3c5f5a96a8fed38cbeda5866b18c29835100267d B 3c78d3be567447c50d10ed52fcfe231525d2bf9c B 3c95b4b01da194ba34a2230dd00a2333d820464a B 3cd23910e77dfb21c9622cf96c5118765a79e03c @@ -544,9 +546,11 @@ B 4bee0d1a83a08c82994ac6bcb22383728134d6b7 B 4c343aa62ea777e6665de45dd950de343a3b5f85 B 4c597e7103f79859ab74b4938e5b2e0495288eb3 B 4cb5fa951bde2f4f2e115cacc1d83bd1aea18150 +B 4ccaa6d5e605ea65978b493dc7bf673ba72a8ed9 B 4d0254adf94a0c73569161a3ed011e53319bce31 B 4d170b09fb600db59fe7dc92c8e3d08bf6c1c3de B 4d718903a14bd6b197473014334d6ba294ecd897 +B 4daa8a05d1851dc1b479b7c3b13e3a892b167f91 B 4daba03ba3ad0f97032c1cebe5547ce6799decdc B 4dc42da1d3621024ba6d9a139367b91a6671f45e B 4df8e2e90f27f317e26594b045f91531fdff52ba @@ -560,6 +564,7 @@ B 5000b9dd5e3396e491f08dac8cd947757fd77ca4 B 501a9ff767f4bdd4183412116f2b45ffa6a1f9b9 B 5027baf5e5f453c7ff92c525c5db48cb3e2e5617 B 5065d9b57a1d5a1fb511190598e40d6683d4b174 +B 5075f93e5f6c67f64fa1c73e9d1ae3e6a01c53ec B 507b03b8e4def1d3da3d5f81e0c105eda1413058 B 5085661fa0b3d6723ffed72386c37d17e7eb75c0 B 5093b5b3e04e0c67ff6ff14e7e7fa3947673a4e8 @@ -683,6 +688,7 @@ B 63f6c6f64192c0a888299be79a4d6d3f6fcce968 B 641eb0a55dc3c5a0f0ef642a3bc652f1f2dbe366 B 642cf8dd0ade538995be3d5cfd90bdd3c5df3f36 B 642f2534d6dba97c2d1fb3fe274f900351b456c3 +B 6463da84d21e77d4fb0f7814902c1f70ea1c2940 B 646618cb1a65427846f28ff9ef432e3bb10b702e B 648bd64e5de7429cc6563413785d9b35d6b79225 B 64a23c3044b21ce4acd722ceafae7997d0c3d841 @@ -803,6 +809,7 @@ B 762719c29c74b78b70789d232b6602d09414789f B 76313002a3149d7fa0445baf11489ce7a5388ff1 B 764404893044c6b11491eb083b220bdf575ed2a1 B 7686ddb3ce2663c2f6923b41ce3948371e17103d +B 76bba771d3ef1234d1f90807789c0a59da1e175b B 76e65e78624d6040f6fa77a6a5ea8804e10087c3 B 76e6684cbb46f3709dd4bfa02041267348cda6c8 B 76ee50f74ddda8125ac71c1133d56e370b7af9c8 @@ -1004,6 +1011,7 @@ B 923117b48a04a07d3549e3ccaf9b2519ad75c527 B 923ad4a992f9d40285a80d6a8e701b0dda4d52ea B 928dac86f1cbb3141204a3570c584bf9e05704a7 B 92c7421290b6f745c6b21c1a609ae73074e7151f +B 931c1a524e7df041a2b2a5bed92dc946f3126fa6 B 939b54221d6e787acae16b21ec977e3a5cbd00dc B 93ea0622ac97b3f0024b3217a76ba820a62eeb94 B 93febc0d4a3a108dc834d280e0fc51e9ad5afd0c @@ -1217,6 +1225,7 @@ B b5aff34f534d7b3cebb67771ad2a624cdfec617a B b5e2667dc0ad34d00e5d838877fe0c1a5255474c B b626840f1571bc927262810f78cd2c307f4ae18d B b632aa139c80589b54bef1e9a7ccef885342f97c +B b646446a55daeece522363bd3afadcaad1a20bb1 B b6d3e153187af3c89b6e3efa2c50979636c2ca45 B b6e6a04205dd763ab71667784926a5d297171a3b B b715067449220f8625d45e54092bc28e22814b0c @@ -1264,6 +1273,7 @@ B bd565683e0696acca674b45e3c312af0120e4a1a B bd624a88b47708daeefc726f8de3ada4a33fdb52 B bd6fc7ef76c99067e6b4699f2fd7dd4d0f480ca7 B bd88de78866e4da2f88a464791e7c44de7c02b37 +B be4a46a90f90840fdb55b3139f5074970e2a6169 B bf459ec393c377dcd4869ccfd4b7fdedcad43920 B bf6da99ae38380a78c1e0ad55eddacb7b32b7e9b B bf8047c90547432bb0e45f8852797e65ea5d4aff @@ -1377,6 +1387,7 @@ B d0f40121063a8924bc02fd31b84d99fd06513573 B d11b7d2524c225f9f4c1cb0f7e772c3956e66eda B d14382ca55d4b74cc581ebbd9aa6676545ff0dda B d19a85fb9a63c7db5f414e8d62324b2b36fca5ea +B d1ada3d1607f9802b971b94a0bcbed464d302e4a B d1cb096f59e2935f00c84ac4f11b96753f11ef87 B d20efdf1abc3f4e0d4b8e0cc2b5d0aa9420c6dd4 B d214d1052a8133571aa1be1dac2896591ca57948 @@ -1479,6
[2/2] cxf git commit: [CXF-6217] Make sure we use XMLStreamReader for unmarshalling
[CXF-6217] Make sure we use XMLStreamReader for unmarshalling Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/5f5be21a Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/5f5be21a Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/5f5be21a Branch: refs/heads/2.7.x-fixes Commit: 5f5be21a69c01848d9772ea6a477ee3e6079fe39 Parents: 3589f95 Author: Daniel Kulp dk...@apache.org Authored: Fri Jan 23 12:46:31 2015 -0500 Committer: Daniel Kulp dk...@apache.org Committed: Fri Jan 23 12:55:22 2015 -0500 -- .../cxf/jaxrs/provider/atom/AtomPojoProvider.java | 14 +- .../java/org/apache/cxf/wsn/jms/JmsPullPoint.java | 6 +- .../java/org/apache/cxf/wsn/jms/JmsSubscription.java | 6 +- 3 files changed, 23 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/5f5be21a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java -- diff --git a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java b/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java index 4e670f6..c1c7237 100644 --- a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java +++ b/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java @@ -47,6 +47,8 @@ import javax.ws.rs.ext.MessageBodyWriter; import javax.ws.rs.ext.Provider; import javax.xml.bind.JAXBContext; import javax.xml.bind.Unmarshaller; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamReader; import org.apache.abdera.Abdera; import org.apache.abdera.factory.Factory; @@ -63,6 +65,7 @@ import org.apache.cxf.jaxrs.provider.JAXBElementProvider; import org.apache.cxf.jaxrs.utils.ExceptionUtils; import org.apache.cxf.jaxrs.utils.InjectionUtils; import org.apache.cxf.jaxrs.utils.JAXRSUtils; +import org.apache.cxf.staxutils.StaxUtils; @Produces({application/atom+xml, application/atom+xml;type=feed, application/atom+xml;type=entry }) @Consumes({application/atom+xml, application/atom+xml;type=feed, application/atom+xml;type=entry }) @@ -658,12 +661,21 @@ public class AtomPojoProvider extends AbstractConfigurableProvider } String entryContent = entry.getContent(); if (entryContent != null) { +XMLStreamReader xreader = StaxUtils.createXMLStreamReader(new StringReader(entryContent)); try { Unmarshaller um = jaxbProvider.getJAXBContext(cls, cls).createUnmarshaller(); -return cls.cast(um.unmarshal(new StringReader(entryContent))); +return cls.cast(um.unmarshal(xreader)); } catch (Exception ex) { reportError(Object of type + cls.getName() + can not be deserialized from Entry, ex, 400); +} finally { +try { +if (xreader != null) { +StaxUtils.close(xreader); +} +} catch (XMLStreamException e) { +//ignore +} } } return null; http://git-wip-us.apache.org/repos/asf/cxf/blob/5f5be21a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java -- diff --git a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java index 4dc25c7..1ac5c00 100644 --- a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java +++ b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java @@ -35,8 +35,10 @@ import javax.jms.Session; import javax.jms.TextMessage; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; +import javax.xml.stream.XMLStreamReader; import org.apache.cxf.common.logging.LogUtils; +import org.apache.cxf.staxutils.StaxUtils; import org.apache.cxf.wsn.AbstractPullPoint; import org.oasis_open.docs.wsn.b_2.NotificationMessageHolderType; import org.oasis_open.docs.wsn.b_2.Notify; @@ -120,7 +122,9 @@ public class JmsPullPoint extends AbstractPullPoint { } TextMessage txtMsg = (TextMessage) msg; StringReader reader = new StringReader(txtMsg.getText()); -Notify notify = (Notify) jaxbContext.createUnmarshaller().unmarshal(reader); +XMLStreamReader xreader = StaxUtils.createXMLStreamReader(reader); +Notify notify = (Notify)
[2/3] cxf git commit: Adding some modified request testing for WS-Security
Adding some modified request testing for WS-Security Conflicts: systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/fault/DoubleItFault.wsdl systests/ws-security/src/test/resources/org/apache/cxf/systest/ws/fault/client.xml Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/d90bfa10 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/d90bfa10 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/d90bfa10 Branch: refs/heads/2.7.x-fixes Commit: d90bfa10439b0dc439816dd1dda417672bd3 Parents: 6a79c36 Author: Colm O hEigeartaigh cohei...@apache.org Authored: Fri Jan 23 16:34:53 2015 + Committer: Colm O hEigeartaigh cohei...@apache.org Committed: Fri Jan 23 16:48:12 2015 + -- .../ws/common/KeystorePasswordCallback.java | 73 .../fault/AbstractModifyRequestInterceptor.java | 102 ++ .../systest/ws/fault/ModifiedRequestServer.java | 47 +++ .../systest/ws/fault/ModifiedRequestTest.java | 335 +++ .../cxf/systest/ws/fault/DoubleItFault.wsdl | 69 .../cxf/systest/ws/fault/client-untrusted.xml | 37 ++ .../org/apache/cxf/systest/ws/fault/client.xml | 51 +++ .../cxf/systest/ws/fault/modified-server.xml| 38 +++ 8 files changed, 752 insertions(+) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/d90bfa10/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java -- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java new file mode 100644 index 000..511155a --- /dev/null +++ b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java @@ -0,0 +1,73 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.cxf.systest.ws.common; + +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import org.apache.wss4j.common.ext.WSPasswordCallback; + +/** + * A CallbackHandler implementation for keystores. + */ +public class KeystorePasswordCallback implements CallbackHandler { + +private MapString, String passwords = +new HashMapString, String(); + +public KeystorePasswordCallback() { +passwords.put(Alice, abcd!1234); +passwords.put(alice, password); +passwords.put(Bob, abcd!1234); +passwords.put(bob, password); +passwords.put(abcd, dcba); +passwords.put(6e0e88f36ebb8744d470f62f604d03ea4ebe5094, password); +passwords.put(wss40rev, security); +passwords.put(morpit, password); +} + +/** + * It attempts to get the password from the private + * alias/passwords map. + */ +public void handle(Callback[] callbacks) throws IOException, UnsupportedCallbackException { +for (int i = 0; i callbacks.length; i++) { +WSPasswordCallback pc = (WSPasswordCallback)callbacks[i]; +if (pc.getUsage() == WSPasswordCallback.PASSWORD_ENCRYPTOR_PASSWORD) { +pc.setPassword(this-is-a-secret); +} else { +String pass = passwords.get(pc.getIdentifier()); +if (pass != null) { +pc.setPassword(pass); +return; +} else { +pc.setPassword(password); +} +} +} +} + + +} http://git-wip-us.apache.org/repos/asf/cxf/blob/d90bfa10/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java
[1/3] cxf git commit: Recording .gitmergeinfo Changes
Repository: cxf Updated Branches: refs/heads/2.7.x-fixes 6a79c3614 - 3589f95c2 Recording .gitmergeinfo Changes Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/5bdf7272 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/5bdf7272 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/5bdf7272 Branch: refs/heads/2.7.x-fixes Commit: 5bdf7272a5733c83a2bb7c14d7c956ee9145adf1 Parents: d90bfa1 Author: Colm O hEigeartaigh cohei...@apache.org Authored: Fri Jan 23 16:48:12 2015 + Committer: Colm O hEigeartaigh cohei...@apache.org Committed: Fri Jan 23 16:48:12 2015 + -- .gitmergeinfo | 1 + 1 file changed, 1 insertion(+) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/5bdf7272/.gitmergeinfo -- diff --git a/.gitmergeinfo b/.gitmergeinfo index 55f01a0..0e60d95 100644 --- a/.gitmergeinfo +++ b/.gitmergeinfo @@ -2265,6 +2265,7 @@ M c558a96f8c460fba3977c5ae6fe1af595b9a3e95 M c650d4d328c3780d3d086824885b18bbfd6e3c3a M c67cf4f4b9ccc4464193d863c29e2cc165edb2c4 M c70e021bc821717a653db28ea09ade8d6c26889e +M c748748b4064e341653aa60aaacde8e770c9aefb M c821f0a3192b8a8041748fb41d8bf85cfbf3afec M c873f990c114ad0256f796226ba14c84c9958ac3 M c91adabdbeaf63599ca61e18acf8a13aa385915b
[3/3] cxf git commit: Fixing backport
Fixing backport Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/3589f95c Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/3589f95c Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/3589f95c Branch: refs/heads/2.7.x-fixes Commit: 3589f95c27df9b8d900cede5907876145e57b4fe Parents: 5bdf727 Author: Colm O hEigeartaigh cohei...@apache.org Authored: Fri Jan 23 17:14:14 2015 + Committer: Colm O hEigeartaigh cohei...@apache.org Committed: Fri Jan 23 17:14:14 2015 + -- .../ws/common/KeystorePasswordCallback.java | 73 .../fault/AbstractModifyRequestInterceptor.java | 3 +- .../systest/ws/fault/ModifiedRequestServer.java | 47 - .../systest/ws/fault/ModifiedRequestTest.java | 48 +++-- .../ws/fault/server/ModifiedRequestServer.java | 47 + .../cxf/systest/ws/fault/DoubleItFault.wsdl | 8 --- .../cxf/systest/ws/fault/client-untrusted.xml | 37 -- .../org/apache/cxf/systest/ws/fault/client.xml | 51 -- .../ws/fault/client/client-untrusted.xml| 39 +++ .../cxf/systest/ws/fault/client/client.xml | 12 .../cxf/systest/ws/fault/modified-server.xml| 38 -- .../systest/ws/fault/server/modified-server.xml | 50 ++ 12 files changed, 174 insertions(+), 279 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/3589f95c/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java -- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java deleted file mode 100644 index 511155a..000 --- a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java +++ /dev/null @@ -1,73 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * License); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - -package org.apache.cxf.systest.ws.common; - -import java.io.IOException; -import java.util.HashMap; -import java.util.Map; - -import javax.security.auth.callback.Callback; -import javax.security.auth.callback.CallbackHandler; -import javax.security.auth.callback.UnsupportedCallbackException; - -import org.apache.wss4j.common.ext.WSPasswordCallback; - -/** - * A CallbackHandler implementation for keystores. - */ -public class KeystorePasswordCallback implements CallbackHandler { - -private MapString, String passwords = -new HashMapString, String(); - -public KeystorePasswordCallback() { -passwords.put(Alice, abcd!1234); -passwords.put(alice, password); -passwords.put(Bob, abcd!1234); -passwords.put(bob, password); -passwords.put(abcd, dcba); -passwords.put(6e0e88f36ebb8744d470f62f604d03ea4ebe5094, password); -passwords.put(wss40rev, security); -passwords.put(morpit, password); -} - -/** - * It attempts to get the password from the private - * alias/passwords map. - */ -public void handle(Callback[] callbacks) throws IOException, UnsupportedCallbackException { -for (int i = 0; i callbacks.length; i++) { -WSPasswordCallback pc = (WSPasswordCallback)callbacks[i]; -if (pc.getUsage() == WSPasswordCallback.PASSWORD_ENCRYPTOR_PASSWORD) { -pc.setPassword(this-is-a-secret); -} else { -String pass = passwords.get(pc.getIdentifier()); -if (pass != null) { -pc.setPassword(pass); -return; -} else { -pc.setPassword(password); -} -} -} -} - - -} http://git-wip-us.apache.org/repos/asf/cxf/blob/3589f95c/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java --
cxf git commit: [CXF-6217] Make sure we use XMLStreamReader for unmarshalling
Repository: cxf Updated Branches: refs/heads/master 9a0203052 - 9f7c1181c [CXF-6217] Make sure we use XMLStreamReader for unmarshalling Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/9f7c1181 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/9f7c1181 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/9f7c1181 Branch: refs/heads/master Commit: 9f7c1181c46fa345e7394d8761661c96d5fbf494 Parents: 9a02030 Author: Daniel Kulp dk...@apache.org Authored: Fri Jan 23 12:46:31 2015 -0500 Committer: Daniel Kulp dk...@apache.org Committed: Fri Jan 23 12:47:00 2015 -0500 -- .../cxf/jaxrs/provider/atom/AtomPojoProvider.java | 14 +- .../java/org/apache/cxf/wsn/jms/JmsPullPoint.java | 6 +- .../java/org/apache/cxf/wsn/jms/JmsSubscription.java | 6 +- 3 files changed, 23 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/9f7c1181/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java -- diff --git a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java b/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java index 4e670f6..c1c7237 100644 --- a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java +++ b/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java @@ -47,6 +47,8 @@ import javax.ws.rs.ext.MessageBodyWriter; import javax.ws.rs.ext.Provider; import javax.xml.bind.JAXBContext; import javax.xml.bind.Unmarshaller; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamReader; import org.apache.abdera.Abdera; import org.apache.abdera.factory.Factory; @@ -63,6 +65,7 @@ import org.apache.cxf.jaxrs.provider.JAXBElementProvider; import org.apache.cxf.jaxrs.utils.ExceptionUtils; import org.apache.cxf.jaxrs.utils.InjectionUtils; import org.apache.cxf.jaxrs.utils.JAXRSUtils; +import org.apache.cxf.staxutils.StaxUtils; @Produces({application/atom+xml, application/atom+xml;type=feed, application/atom+xml;type=entry }) @Consumes({application/atom+xml, application/atom+xml;type=feed, application/atom+xml;type=entry }) @@ -658,12 +661,21 @@ public class AtomPojoProvider extends AbstractConfigurableProvider } String entryContent = entry.getContent(); if (entryContent != null) { +XMLStreamReader xreader = StaxUtils.createXMLStreamReader(new StringReader(entryContent)); try { Unmarshaller um = jaxbProvider.getJAXBContext(cls, cls).createUnmarshaller(); -return cls.cast(um.unmarshal(new StringReader(entryContent))); +return cls.cast(um.unmarshal(xreader)); } catch (Exception ex) { reportError(Object of type + cls.getName() + can not be deserialized from Entry, ex, 400); +} finally { +try { +if (xreader != null) { +StaxUtils.close(xreader); +} +} catch (XMLStreamException e) { +//ignore +} } } return null; http://git-wip-us.apache.org/repos/asf/cxf/blob/9f7c1181/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java -- diff --git a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java index 4dc25c7..1ac5c00 100644 --- a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java +++ b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java @@ -35,8 +35,10 @@ import javax.jms.Session; import javax.jms.TextMessage; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; +import javax.xml.stream.XMLStreamReader; import org.apache.cxf.common.logging.LogUtils; +import org.apache.cxf.staxutils.StaxUtils; import org.apache.cxf.wsn.AbstractPullPoint; import org.oasis_open.docs.wsn.b_2.NotificationMessageHolderType; import org.oasis_open.docs.wsn.b_2.Notify; @@ -120,7 +122,9 @@ public class JmsPullPoint extends AbstractPullPoint { } TextMessage txtMsg = (TextMessage) msg; StringReader reader = new StringReader(txtMsg.getText()); -Notify notify = (Notify) jaxbContext.createUnmarshaller().unmarshal(reader); +XMLStreamReader xreader = StaxUtils.createXMLStreamReader(reader); +
cxf git commit: [CXF-6217] Make sure we use XMLStreamReader for unmarshalling
Repository: cxf Updated Branches: refs/heads/3.0.x-fixes ea6d2f7dd - 3c874549a [CXF-6217] Make sure we use XMLStreamReader for unmarshalling Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/3c874549 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/3c874549 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/3c874549 Branch: refs/heads/3.0.x-fixes Commit: 3c874549a1c9653482f83f874003b1442d7379ae Parents: ea6d2f7 Author: Daniel Kulp dk...@apache.org Authored: Fri Jan 23 12:46:31 2015 -0500 Committer: Daniel Kulp dk...@apache.org Committed: Fri Jan 23 12:54:08 2015 -0500 -- .../cxf/jaxrs/provider/atom/AtomPojoProvider.java | 14 +- .../java/org/apache/cxf/wsn/jms/JmsPullPoint.java | 6 +- .../java/org/apache/cxf/wsn/jms/JmsSubscription.java | 6 +- 3 files changed, 23 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/3c874549/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java -- diff --git a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java b/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java index 4e670f6..c1c7237 100644 --- a/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java +++ b/rt/rs/extensions/providers/src/main/java/org/apache/cxf/jaxrs/provider/atom/AtomPojoProvider.java @@ -47,6 +47,8 @@ import javax.ws.rs.ext.MessageBodyWriter; import javax.ws.rs.ext.Provider; import javax.xml.bind.JAXBContext; import javax.xml.bind.Unmarshaller; +import javax.xml.stream.XMLStreamException; +import javax.xml.stream.XMLStreamReader; import org.apache.abdera.Abdera; import org.apache.abdera.factory.Factory; @@ -63,6 +65,7 @@ import org.apache.cxf.jaxrs.provider.JAXBElementProvider; import org.apache.cxf.jaxrs.utils.ExceptionUtils; import org.apache.cxf.jaxrs.utils.InjectionUtils; import org.apache.cxf.jaxrs.utils.JAXRSUtils; +import org.apache.cxf.staxutils.StaxUtils; @Produces({application/atom+xml, application/atom+xml;type=feed, application/atom+xml;type=entry }) @Consumes({application/atom+xml, application/atom+xml;type=feed, application/atom+xml;type=entry }) @@ -658,12 +661,21 @@ public class AtomPojoProvider extends AbstractConfigurableProvider } String entryContent = entry.getContent(); if (entryContent != null) { +XMLStreamReader xreader = StaxUtils.createXMLStreamReader(new StringReader(entryContent)); try { Unmarshaller um = jaxbProvider.getJAXBContext(cls, cls).createUnmarshaller(); -return cls.cast(um.unmarshal(new StringReader(entryContent))); +return cls.cast(um.unmarshal(xreader)); } catch (Exception ex) { reportError(Object of type + cls.getName() + can not be deserialized from Entry, ex, 400); +} finally { +try { +if (xreader != null) { +StaxUtils.close(xreader); +} +} catch (XMLStreamException e) { +//ignore +} } } return null; http://git-wip-us.apache.org/repos/asf/cxf/blob/3c874549/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java -- diff --git a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java index 4dc25c7..1ac5c00 100644 --- a/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java +++ b/services/wsn/wsn-core/src/main/java/org/apache/cxf/wsn/jms/JmsPullPoint.java @@ -35,8 +35,10 @@ import javax.jms.Session; import javax.jms.TextMessage; import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; +import javax.xml.stream.XMLStreamReader; import org.apache.cxf.common.logging.LogUtils; +import org.apache.cxf.staxutils.StaxUtils; import org.apache.cxf.wsn.AbstractPullPoint; import org.oasis_open.docs.wsn.b_2.NotificationMessageHolderType; import org.oasis_open.docs.wsn.b_2.Notify; @@ -120,7 +122,9 @@ public class JmsPullPoint extends AbstractPullPoint { } TextMessage txtMsg = (TextMessage) msg; StringReader reader = new StringReader(txtMsg.getText()); -Notify notify = (Notify) jaxbContext.createUnmarshaller().unmarshal(reader); +XMLStreamReader xreader =
cxf git commit: [CXF-6178] Make everything about netty completely optional.
Repository: cxf Updated Branches: refs/heads/3.0.x-fixes c748748b4 - ea6d2f7dd [CXF-6178] Make everything about netty completely optional. Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/ea6d2f7d Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/ea6d2f7d Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/ea6d2f7d Branch: refs/heads/3.0.x-fixes Commit: ea6d2f7dd9c0105c2c0693cc90a8f563f30a1928 Parents: c748748 Author: Daniel Kulp dk...@apache.org Authored: Fri Jan 23 11:45:04 2015 -0500 Committer: Daniel Kulp dk...@apache.org Committed: Fri Jan 23 11:53:19 2015 -0500 -- .../src/main/resources/META-INF/cxf/bus-extensions.txt | 2 +- .../src/main/resources/META-INF/cxf/bus-extensions.txt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/ea6d2f7d/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt -- diff --git a/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt b/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt index b63a389..9e62cc6 100644 --- a/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt +++ b/rt/transports/http-netty/netty-client/src/main/resources/META-INF/cxf/bus-extensions.txt @@ -1,2 +1,2 @@ -org.apache.cxf.transport.http.netty.client.NettyHttpTransportFactory::true +org.apache.cxf.transport.http.netty.client.NettyHttpTransportFactory::true:true org.apache.cxf.transport.http.netty.client.NettyHttpConduitFactory::true:true http://git-wip-us.apache.org/repos/asf/cxf/blob/ea6d2f7d/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt -- diff --git a/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt b/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt index d7f4cbb..5006ab2 100644 --- a/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt +++ b/rt/transports/http-netty/netty-server/src/main/resources/META-INF/cxf/bus-extensions.txt @@ -1,3 +1,3 @@ -org.apache.cxf.transport.http.netty.server.NettyHttpTransportFactory::true +org.apache.cxf.transport.http.netty.server.NettyHttpTransportFactory::true:true org.apache.cxf.transport.http.netty.server.NettyHttpDestinationFactory::true:true -org.apache.cxf.transport.http.netty.server.NettyHttpServerEngineFactory::true +org.apache.cxf.transport.http.netty.server.NettyHttpServerEngineFactory::true:true
cxf git commit: Adding some modified request testing for WS-Security
Repository: cxf Updated Branches: refs/heads/master b6ccc894f - 3c47717aa Adding some modified request testing for WS-Security Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/3c47717a Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/3c47717a Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/3c47717a Branch: refs/heads/master Commit: 3c47717aad9adb65ac79fa93af4ebad0cf74e3e3 Parents: b6ccc89 Author: Colm O hEigeartaigh cohei...@apache.org Authored: Fri Jan 23 16:34:53 2015 + Committer: Colm O hEigeartaigh cohei...@apache.org Committed: Fri Jan 23 16:35:14 2015 + -- .../ws/common/KeystorePasswordCallback.java | 1 + .../fault/AbstractModifyRequestInterceptor.java | 102 ++ .../systest/ws/fault/ModifiedRequestServer.java | 47 +++ .../systest/ws/fault/ModifiedRequestTest.java | 335 +++ .../cxf/systest/ws/fault/DoubleItFault.wsdl | 63 .../cxf/systest/ws/fault/client-untrusted.xml | 37 ++ .../org/apache/cxf/systest/ws/fault/client.xml | 10 + .../cxf/systest/ws/fault/modified-server.xml| 38 +++ 8 files changed, 633 insertions(+) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/3c47717a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java -- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java index aad0518..511155a 100644 --- a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java +++ b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/common/KeystorePasswordCallback.java @@ -45,6 +45,7 @@ public class KeystorePasswordCallback implements CallbackHandler { passwords.put(abcd, dcba); passwords.put(6e0e88f36ebb8744d470f62f604d03ea4ebe5094, password); passwords.put(wss40rev, security); +passwords.put(morpit, password); } /** http://git-wip-us.apache.org/repos/asf/cxf/blob/3c47717a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java -- diff --git a/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java new file mode 100644 index 000..53432e9 --- /dev/null +++ b/systests/ws-security/src/test/java/org/apache/cxf/systest/ws/fault/AbstractModifyRequestInterceptor.java @@ -0,0 +1,102 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * License); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.cxf.systest.ws.fault; + +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.Iterator; +import java.util.Set; + +import javax.xml.namespace.QName; +import javax.xml.soap.SOAPException; +import javax.xml.soap.SOAPHeaderElement; +import javax.xml.soap.SOAPMessage; + +import org.w3c.dom.Element; + +import org.apache.cxf.binding.soap.SoapMessage; +import org.apache.cxf.binding.soap.saaj.SAAJUtils; +import org.apache.cxf.interceptor.Fault; +import org.apache.cxf.message.Message; +import org.apache.cxf.phase.Phase; +import org.apache.cxf.phase.PhaseInterceptor; +import org.apache.cxf.ws.security.wss4j.PolicyBasedWSS4JOutInterceptor; +import org.apache.wss4j.dom.WSConstants; + +public abstract class AbstractModifyRequestInterceptor implements PhaseInterceptorSoapMessage { + +private static final QName SEC_HEADER = +new QName(WSConstants.WSSE_NS, WSConstants.WSSE_LN, WSConstants.WSSE_PREFIX); +private SetString afterInterceptors = new HashSetString(); + +public AbstractModifyRequestInterceptor() { +getAfter().add(PolicyBasedWSS4JOutInterceptor.class.getName()); +} + +public void
cxf git commit: Minor update to the subresource proxy creation code
Repository: cxf Updated Branches: refs/heads/master 6ec790ce3 - b6ccc894f Minor update to the subresource proxy creation code Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/b6ccc894 Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/b6ccc894 Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/b6ccc894 Branch: refs/heads/master Commit: b6ccc894f3081d9c783f6da8184a9572667ebff5 Parents: 6ec790c Author: Sergey Beryozkin sberyoz...@talend.com Authored: Fri Jan 23 16:24:33 2015 + Committer: Sergey Beryozkin sberyoz...@talend.com Committed: Fri Jan 23 16:24:33 2015 + -- .../main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/b6ccc894/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java -- diff --git a/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java b/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java index b10de68..167ae73 100644 --- a/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java +++ b/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java @@ -372,7 +372,7 @@ public final class JAXRSClientFactory { static T T createProxy(ClassT cls, ClassLoader loader, InvocationHandler handler) { return cls.cast(ProxyHelper.getProxy(loader == null ? cls.getClassLoader() : loader, - new Class[]{Client.class, cls}, + new Class[]{Client.class, InvocationHandlerAware.class, cls}, handler)); }
cxf git commit: Minor update to the subresource proxy creation code
Repository: cxf Updated Branches: refs/heads/3.0.x-fixes ebdbe885a - be929cdcb Minor update to the subresource proxy creation code Project: http://git-wip-us.apache.org/repos/asf/cxf/repo Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/be929cdc Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/be929cdc Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/be929cdc Branch: refs/heads/3.0.x-fixes Commit: be929cdcbb17a9c421e7e3c724ddbf02dc558c63 Parents: ebdbe88 Author: Sergey Beryozkin sberyoz...@talend.com Authored: Fri Jan 23 16:24:33 2015 + Committer: Sergey Beryozkin sberyoz...@talend.com Committed: Fri Jan 23 16:26:25 2015 + -- .../main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/cxf/blob/be929cdc/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java -- diff --git a/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java b/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java index b10de68..167ae73 100644 --- a/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java +++ b/rt/rs/client/src/main/java/org/apache/cxf/jaxrs/client/JAXRSClientFactory.java @@ -372,7 +372,7 @@ public final class JAXRSClientFactory { static T T createProxy(ClassT cls, ClassLoader loader, InvocationHandler handler) { return cls.cast(ProxyHelper.getProxy(loader == null ? cls.getClassLoader() : loader, - new Class[]{Client.class, cls}, + new Class[]{Client.class, InvocationHandlerAware.class, cls}, handler)); }