JBossWS SVN: r18824 - in container/wildfly80/branches/jbossws-wildfly800/server-integration/src: main/java/org/jboss/as/webservices/dmr and 1 other directories.
by jbossws-commits@lists.jboss.org
Author: rsearls
Date: 2014-07-29 14:00:00 -0400 (Tue, 29 Jul 2014)
New Revision: 18824
Modified:
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/config/ServerConfigImpl.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Attributes.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Constants.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Element.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSServerConfigAttributeHandler.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemAdd.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemReader.java
container/wildfly80/branches/jbossws-wildfly800/server-integration/src/test/java/org/jboss/as/webservices/config/ServerConfigImplTestCase.java
Log:
[JBWS-3750] integration of WebServicePathRewriteRule
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/config/ServerConfigImpl.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/config/ServerConfigImpl.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/config/ServerConfigImpl.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -52,6 +52,7 @@
private final DMRSynchCheckHandler webServicePortUCH = new DMRSynchCheckHandler();
private final DMRSynchCheckHandler webServiceSecurePortUCH = new DMRSynchCheckHandler();
private final DMRSynchCheckHandler modifySOAPAddressUCH = new DMRSynchCheckHandler();
+ private final DMRSynchCheckHandler webServicePathRewriteRuleUCH = new DMRSynchCheckHandler();
private ServerConfigImpl() {
// forbidden inheritance
@@ -65,6 +66,7 @@
webServicePortUCH.reset();
webServiceSecurePortUCH.reset();
modifySOAPAddressUCH.reset();
+ webServicePathRewriteRuleUCH.reset();
}
public void incrementWSDeploymentCount() {
@@ -89,6 +91,15 @@
setWebServiceHost(host, webServiceHostUCH);
}
+ public void setWebServicePathRewriteRule(String path, boolean forceUpdate) {
+ setWebServicePathRewriteRule(path, forceUpdate ? null : webServicePathRewriteRuleUCH);
+ }
+
+ @Override
+ public void setWebServicePathRewriteRule(String path) {
+ setWebServicePathRewriteRule(path, webServicePathRewriteRuleUCH);
+ }
+
public void setWebServicePort(int port, boolean forceUpdate) {
setWebServicePort(port, forceUpdate ? null : webServicePortUCH);
}
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Attributes.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Attributes.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Attributes.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -61,8 +61,14 @@
.setDefaultValue(new ModelNode(true))
.setAllowExpression(true)
.build();
- SimpleAttributeDefinition[] SUBSYSTEM_ATTRIBUTES = {MODIFY_WSDL_ADDRESS, WSDL_HOST, WSDL_PORT, WSDL_SECURE_PORT};
+ SimpleAttributeDefinition WSDL_PATH_REWRITE_RULE = new SimpleAttributeDefinitionBuilder(Constants.WSDL_PATH_REWRITE_RULE, ModelType.STRING)
+ .setAllowNull(true)
+ .setAllowExpression(false)
+ .build();
+
+ SimpleAttributeDefinition[] SUBSYSTEM_ATTRIBUTES = {MODIFY_WSDL_ADDRESS, WSDL_HOST, WSDL_PORT, WSDL_SECURE_PORT, WSDL_PATH_REWRITE_RULE};
+
SimpleAttributeDefinition VALUE = new SimpleAttributeDefinitionBuilder(Constants.VALUE, ModelType.STRING)
.setAllowNull(true)
.setAllowExpression(true)
@@ -77,5 +83,4 @@
.setAllowExpression(true)
.build();
-
}
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Constants.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Constants.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Constants.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -55,4 +55,5 @@
String HANDLER_NAME="handler-name";
String HANDLER_CLASS="handler-class";
String VALUE = "value";
+ String WSDL_PATH_REWRITE_RULE = "wsdl-path-rewrite-rule";
}
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Element.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Element.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/Element.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -39,6 +39,7 @@
WSDL_HOST(Constants.WSDL_HOST),
WSDL_PORT(Constants.WSDL_PORT),
WSDL_SECURE_PORT(Constants.WSDL_SECURE_PORT),
+ WSDL_PATH_REWRITE_RULE(Constants.WSDL_PATH_REWRITE_RULE),
CLIENT_CONFIG(Constants.CLIENT_CONFIG),
ENDPOINT_CONFIG(Constants.ENDPOINT_CONFIG),
CONFIG_NAME(Constants.CONFIG_NAME),
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSServerConfigAttributeHandler.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSServerConfigAttributeHandler.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSServerConfigAttributeHandler.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -25,6 +25,7 @@
import static org.jboss.as.webservices.dmr.Constants.WSDL_HOST;
import static org.jboss.as.webservices.dmr.Constants.WSDL_PORT;
import static org.jboss.as.webservices.dmr.Constants.WSDL_SECURE_PORT;
+import static org.jboss.as.webservices.dmr.Constants.WSDL_PATH_REWRITE_RULE;
import java.net.UnknownHostException;
@@ -107,6 +108,9 @@
} else if (WSDL_SECURE_PORT.equals(attributeName)) {
final int securePort = value != null ? Integer.parseInt(value) : -1;
config.setWebServiceSecurePort(securePort, isRevert);
+ } else if (WSDL_PATH_REWRITE_RULE.equals(attributeName)) {
+ final String path = value != null ? value : null;
+ config.setWebServicePathRewriteRule(path, isRevert);
} else {
throw new IllegalArgumentException(attributeName);
}
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemAdd.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemAdd.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemAdd.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -26,6 +26,7 @@
import static org.jboss.as.webservices.dmr.Constants.WSDL_HOST;
import static org.jboss.as.webservices.dmr.Constants.WSDL_PORT;
import static org.jboss.as.webservices.dmr.Constants.WSDL_SECURE_PORT;
+import static org.jboss.as.webservices.dmr.Constants.WSDL_PATH_REWRITE_RULE;
import java.net.UnknownHostException;
import java.util.ArrayList;
@@ -112,6 +113,9 @@
if (configuration.hasDefined(WSDL_SECURE_PORT)) {
config.setWebServiceSecurePort(Attributes.WSDL_SECURE_PORT.resolveModelAttribute(context, configuration).asInt());
}
+ if (configuration.hasDefined(WSDL_PATH_REWRITE_RULE)) {
+ config.setWebServicePathRewriteRule(Attributes.WSDL_PATH_REWRITE_RULE.resolveModelAttribute(context, configuration).asString());
+ }
return config;
}
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemReader.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemReader.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/main/java/org/jboss/as/webservices/dmr/WSSubsystemReader.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -140,6 +140,11 @@
Attributes.WSDL_SECURE_PORT.parseAndSetParameter(value, subsystem, reader);
break;
}
+ case WSDL_PATH_REWRITE_RULE: {
+ final String value = parseElementNoAttributes(reader);
+ Attributes.WSDL_PATH_REWRITE_RULE.parseAndSetParameter(value, subsystem, reader);
+ break;
+ }
case ENDPOINT_CONFIG: {
readConfig(reader, address, endpointConfigs, false);
break;
Modified: container/wildfly80/branches/jbossws-wildfly800/server-integration/src/test/java/org/jboss/as/webservices/config/ServerConfigImplTestCase.java
===================================================================
--- container/wildfly80/branches/jbossws-wildfly800/server-integration/src/test/java/org/jboss/as/webservices/config/ServerConfigImplTestCase.java 2014-07-29 17:58:28 UTC (rev 18823)
+++ container/wildfly80/branches/jbossws-wildfly800/server-integration/src/test/java/org/jboss/as/webservices/config/ServerConfigImplTestCase.java 2014-07-29 18:00:00 UTC (rev 18824)
@@ -92,6 +92,12 @@
sc.setWebServiceSecurePort(5435);
}
});
+ internalTestSingleAttributeUpdate(new Callback() {
+ @Override
+ public void setAttribute(ServerConfig sc) throws Exception {
+ sc.setWebServicePathRewriteRule("MY/TEST/PATH");
+ }
+ });
}
@Test
@@ -120,10 +126,17 @@
sc.setWebServiceSecurePort(5435);
}
};
- internalTestMultipleAttributeUpdate(cbA, new Callback[]{cbB, cbC, cbD});
- internalTestMultipleAttributeUpdate(cbB, new Callback[]{cbA, cbC, cbD});
- internalTestMultipleAttributeUpdate(cbC, new Callback[]{cbA, cbB, cbD});
- internalTestMultipleAttributeUpdate(cbD, new Callback[]{cbA, cbB, cbC});
+ Callback cbE = new Callback() {
+ @Override
+ public void setAttribute(ServerConfig sc) throws Exception {
+ sc.setWebServicePathRewriteRule("MY/TEST/PATH");
+ }
+ };
+ internalTestMultipleAttributeUpdate(cbA, new Callback[]{cbB, cbC, cbD, cbE});
+ internalTestMultipleAttributeUpdate(cbB, new Callback[]{cbA, cbC, cbD, cbE});
+ internalTestMultipleAttributeUpdate(cbC, new Callback[]{cbA, cbB, cbD, cbE});
+ internalTestMultipleAttributeUpdate(cbD, new Callback[]{cbA, cbB, cbC, cbE});
+ internalTestMultipleAttributeUpdate(cbE, new Callback[]{cbA, cbB, cbC, cbD});
}
protected void internalTestSingleAttributeUpdate(Callback cb) throws Exception {
10 years, 4 months
JBossWS SVN: r18823 - common/trunk/src/main/java/org/jboss/ws/common/management.
by jbossws-commits@lists.jboss.org
Author: rsearls
Date: 2014-07-29 13:58:28 -0400 (Tue, 29 Jul 2014)
New Revision: 18823
Modified:
common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfig.java
common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfigMBean.java
Log:
[JBWS-3750] integration of WebServicePathRewriteRule
Modified: common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfig.java
===================================================================
--- common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfig.java 2014-07-29 17:57:52 UTC (rev 18822)
+++ common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfig.java 2014-07-29 17:58:28 UTC (rev 18823)
@@ -81,7 +81,11 @@
// Whether we should always modify the soap address to the deployed endpoint location
private volatile boolean modifySOAPAddress;
private final Object modifySOAPAddressLock = new Object();
-
+
+ // The SOAP address path component for substitution in the existing SOAP address.
+ private volatile String webServicePathRewriteRule;
+ private final Object webServicePathRewriteRuleLock = new Object();
+
private volatile boolean statisticsEnabled;
//The stack config
@@ -262,7 +266,28 @@
return localPort;
}
}
-
+
+ public String getWebServicePathRewriteRule()
+ {
+ return webServicePathRewriteRule;
+ }
+
+ public void setWebServicePathRewriteRule(String path)
+ {
+ setWebServicePathRewriteRule(path, null);
+ }
+
+ public void setWebServicePathRewriteRule(String path, UpdateCallbackHandler uch)
+ {
+ synchronized (webServicePathRewriteRuleLock) {
+ if (uch != null)
+ {
+ uch.onBeforeUpdate();
+ }
+ this.webServicePathRewriteRule = path;
+ }
+ }
+
private int getConnectorPort(boolean secure) {
final ClassLoader cl = ClassLoaderProvider.getDefaultProvider().getServerIntegrationClassLoader();
int port = 0;
@@ -389,4 +414,4 @@
public interface UpdateCallbackHandler {
public void onBeforeUpdate();
}
-}
\ No newline at end of file
+}
Modified: common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfigMBean.java
===================================================================
--- common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfigMBean.java 2014-07-29 17:57:52 UTC (rev 18822)
+++ common/trunk/src/main/java/org/jboss/ws/common/management/AbstractServerConfigMBean.java 2014-07-29 17:58:28 UTC (rev 18823)
@@ -58,4 +58,8 @@
boolean isModifySOAPAddress();
void setModifySOAPAddress(boolean flag);
+
+ String getWebServicePathRewriteRule();
+
+ void setWebServicePathRewriteRule(String path);
}
10 years, 4 months
JBossWS SVN: r18822 - spi/trunk/src/main/java/org/jboss/wsf/spi/management.
by jbossws-commits@lists.jboss.org
Author: rsearls
Date: 2014-07-29 13:57:52 -0400 (Tue, 29 Jul 2014)
New Revision: 18822
Modified:
spi/trunk/src/main/java/org/jboss/wsf/spi/management/ServerConfig.java
Log:
[JBWS-3750] integration of WebServicePathRewriteRule
Modified: spi/trunk/src/main/java/org/jboss/wsf/spi/management/ServerConfig.java
===================================================================
--- spi/trunk/src/main/java/org/jboss/wsf/spi/management/ServerConfig.java 2014-07-29 07:16:22 UTC (rev 18821)
+++ spi/trunk/src/main/java/org/jboss/wsf/spi/management/ServerConfig.java 2014-07-29 17:57:52 UTC (rev 18822)
@@ -60,6 +60,9 @@
int getWebServiceSecurePort();
void setWebServiceSecurePort(int port);
+
+ String getWebServicePathRewriteRule();
+ void setWebServicePathRewriteRule(String path);
boolean isModifySOAPAddress();
10 years, 4 months
JBossWS SVN: r18821 - in stack/cxf/trunk/modules: client/src/main/java/org/jboss/wsf/stack/cxf/client and 4 other directories.
by jbossws-commits@lists.jboss.org
Author: asoldano
Date: 2014-07-29 03:16:22 -0400 (Tue, 29 Jul 2014)
New Revision: 18821
Added:
stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/SecurityProviderConfig.java
Modified:
stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/Loggers.java
stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/Constants.java
stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSNonSpringBusFactory.java
stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSSpringBusFactory.java
stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/jboss/ws/jaxws-client/main/module.xml
stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/jboss/ws/jaxws-client/main/module.xml
stack/cxf/trunk/modules/server/src/main/java/org/jboss/wsf/stack/cxf/config/CXFStackConfigFactory.java
Log:
[JBWS-3817] Avoid globally installing BouncyCastle
Modified: stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/Loggers.java
===================================================================
--- stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/Loggers.java 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/Loggers.java 2014-07-29 07:16:22 UTC (rev 18821)
@@ -228,4 +228,8 @@
@LogMessage(level = DEBUG)
@Message(id = 24102, value = "JASPI authentication isn't enabled, can not find JASPI modules and classes")
void cannotFindJaspiClasses();
+
+ @LogMessage(level = DEBUG)
+ @Message(id = 24103, value = "Could not load BouncyCastle security provider; either setup your classpath properly or prevent loading by using the '%s' system property.")
+ void cannotLoadBouncyCastleProvider(String property, @Cause Throwable cause);
}
Modified: stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/Constants.java
===================================================================
--- stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/Constants.java 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/Constants.java 2014-07-29 07:16:22 UTC (rev 18821)
@@ -44,6 +44,7 @@
public static final String CXF_MANAGEMENT_INSTALL_RESPONSE_TIME_INTERCEPTORS = "cxf.management.installResponseTimeInterceptors";
public static final String CXF_WS_DISCOVERY_ENABLED = "cxf.ws-discovery.enabled";
public static final String JBWS_CXF_DISABLE_HANDLER_AUTH_CHECKS = "org.jboss.ws.cxf.disableHandlerAuthChecks";
+ public static final String JBWS_CXF_NO_LOCAL_BC = "org.jboss.ws.cxf.noLocalBC";
public static final String JBWS_CXF_JAXWS_CLIENT_BUS_STRATEGY = "org.jboss.ws.cxf.jaxws-client.bus.strategy";
public static final String THREAD_BUS_STRATEGY = "THREAD_BUS";
Modified: stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSNonSpringBusFactory.java
===================================================================
--- stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSNonSpringBusFactory.java 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSNonSpringBusFactory.java 2014-07-29 07:16:22 UTC (rev 18821)
@@ -66,5 +66,6 @@
super.initializeBus(bus);
final ResourceManager resourceManager = bus.getExtension(ResourceManager.class);
resourceManager.addResourceResolver(JBossWSResourceInjectionResolver.getInstance());
+ SecurityProviderConfig.setup(bus);
}
}
Modified: stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSSpringBusFactory.java
===================================================================
--- stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSSpringBusFactory.java 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/JBossWSSpringBusFactory.java 2014-07-29 07:16:22 UTC (rev 18821)
@@ -154,6 +154,7 @@
super.initializeBus(bus);
final ResourceManager resourceManager = bus.getExtension(ResourceManager.class);
resourceManager.addResourceResolver(JBossWSResourceInjectionResolver.getInstance());
+ SecurityProviderConfig.setup(bus);
}
void registerAppContextLifeCycleListener(final Bus bus, final BusApplicationContext bac)
Added: stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/SecurityProviderConfig.java
===================================================================
--- stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/SecurityProviderConfig.java (rev 0)
+++ stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/SecurityProviderConfig.java 2014-07-29 07:16:22 UTC (rev 18821)
@@ -0,0 +1,115 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2014, Red Hat Middleware LLC, and individual contributors
+ * as indicated by the @author tags. See the copyright.txt file in the
+ * distribution for a full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.wsf.stack.cxf.client.configuration;
+
+import java.security.AccessController;
+import java.security.PrivilegedAction;
+import java.security.Provider;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.interceptor.Fault;
+import org.apache.cxf.message.Exchange;
+import org.apache.cxf.message.Message;
+import org.apache.cxf.phase.AbstractPhaseInterceptor;
+import org.apache.cxf.phase.Phase;
+import org.jboss.wsf.stack.cxf.Loggers;
+import org.jboss.wsf.stack.cxf.client.Constants;
+
+
+/**
+ * Convenient class for setting a BouncyCastle security provider
+ * through CXF interceptors when not globally available.
+ *
+ * @author alessio.soldano(a)jboss.com
+ * @since 28-Jul-2014
+ */
+public class SecurityProviderConfig
+{
+ public static final boolean BC_GLOBALLY_AVAILABLE = java.security.Security.getProvider("BC") != null;
+ static {
+ if (BC_GLOBALLY_AVAILABLE) {
+ useIvParameterSpec();
+ }
+ }
+ private static final boolean NO_LOCAL_BC = SecurityActions.getBoolean(Constants.JBWS_CXF_NO_LOCAL_BC);
+ private static Provider provider;
+
+ private static synchronized Provider getBCProvider() {
+ if (provider == null) {
+ try {
+ Class<?> clazz = SecurityProviderConfig.class.getClassLoader().loadClass("org.bouncycastle.jce.provider.BouncyCastleProvider");
+ provider = (Provider)clazz.newInstance();
+ if (provider.getVersion() < 1.50) {
+ useIvParameterSpec();
+ }
+ } catch (Throwable t) {
+ Loggers.ROOT_LOGGER.cannotLoadBouncyCastleProvider(Constants.JBWS_CXF_NO_LOCAL_BC, t);
+ }
+ }
+ return provider;
+ }
+
+
+ public static void setup(Bus bus) {
+ if (!NO_LOCAL_BC && !BC_GLOBALLY_AVAILABLE) {
+ Provider p = getBCProvider();
+ if (p != null) {
+ bus.getInInterceptors().add(new Interceptor(Phase.RECEIVE));
+ bus.getOutInterceptors().add(new Interceptor(Phase.SETUP));
+ }
+ }
+ }
+
+ private static class Interceptor extends AbstractPhaseInterceptor<Message> {
+
+ public Interceptor(String phase)
+ {
+ super(phase);
+ }
+
+ @Override
+ public void handleMessage(Message message) throws Fault
+ {
+ Exchange exchange = message.getExchange();
+ exchange.put(Provider.class, getBCProvider());
+ }
+ }
+
+ private static void useIvParameterSpec() {
+ try {
+ // Don't override if it was set explicitly
+ AccessController.doPrivileged(new PrivilegedAction<Boolean>() {
+ public Boolean run() {
+ String ivParameterSpec = "org.apache.xml.security.cipher.gcm.useIvParameterSpec";
+ if (System.getProperty(ivParameterSpec) == null) {
+ System.setProperty(ivParameterSpec, "true");
+ return false;
+ }
+ return true;
+ }
+ });
+ } catch (Throwable t) {
+ //ignore
+ }
+ }
+
+}
Property changes on: stack/cxf/trunk/modules/client/src/main/java/org/jboss/wsf/stack/cxf/client/configuration/SecurityProviderConfig.java
___________________________________________________________________
Added: svn:keywords
+ Rev Date
Added: svn:eol-style
+ native
Modified: stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/jboss/ws/jaxws-client/main/module.xml
===================================================================
--- stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/jboss/ws/jaxws-client/main/module.xml 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/jboss/ws/jaxws-client/main/module.xml 2014-07-29 07:16:22 UTC (rev 18821)
@@ -73,5 +73,6 @@
</imports>
</module>
<module name="javax.wsdl4j.api" />
+ <module name="org.bouncycastle" />
</dependencies>
</module>
Modified: stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/jboss/ws/jaxws-client/main/module.xml
===================================================================
--- stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/jboss/ws/jaxws-client/main/module.xml 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/jboss/ws/jaxws-client/main/module.xml 2014-07-29 07:16:22 UTC (rev 18821)
@@ -73,5 +73,6 @@
</imports>
</module>
<module name="javax.wsdl4j.api" />
+ <module name="org.bouncycastle" />
</dependencies>
</module>
Modified: stack/cxf/trunk/modules/server/src/main/java/org/jboss/wsf/stack/cxf/config/CXFStackConfigFactory.java
===================================================================
--- stack/cxf/trunk/modules/server/src/main/java/org/jboss/wsf/stack/cxf/config/CXFStackConfigFactory.java 2014-07-29 06:43:00 UTC (rev 18820)
+++ stack/cxf/trunk/modules/server/src/main/java/org/jboss/wsf/stack/cxf/config/CXFStackConfigFactory.java 2014-07-29 07:16:22 UTC (rev 18821)
@@ -26,7 +26,7 @@
import java.security.AccessController;
import java.security.PrivilegedAction;
-import org.apache.wss4j.dom.WSSConfig;
+import org.apache.wss4j.common.crypto.WSProviderConfig;
import org.jboss.wsf.spi.classloading.ClassLoaderProvider;
import org.jboss.wsf.spi.management.StackConfig;
import org.jboss.wsf.spi.management.StackConfigFactory;
@@ -48,7 +48,6 @@
class CXFStackConfig implements StackConfig
{
-
public CXFStackConfig()
{
final ClassLoader orig = getContextClassLoader();
@@ -58,7 +57,7 @@
try
{
setContextClassLoader(ClassLoaderProvider.getDefaultProvider().getServerIntegrationClassLoader());
- WSSConfig.init();
+ WSProviderConfig.init(true, false, true);
}
catch (Exception e)
{
10 years, 4 months
JBossWS SVN: r18820 - stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsse/policy/trust.
by jbossws-commits@lists.jboss.org
Author: asoldano
Date: 2014-07-29 02:43:00 -0400 (Tue, 29 Jul 2014)
New Revision: 18820
Modified:
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustBearerTestCase.java
Log:
Modified: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustBearerTestCase.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustBearerTestCase.java 2014-07-28 14:20:29 UTC (rev 18819)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustBearerTestCase.java 2014-07-29 06:43:00 UTC (rev 18820)
@@ -51,7 +51,7 @@
{
//deploy client, STS and service; start a security domain to be used by the STS for authenticating client
JBossWSCXFTestSetup testSetup = WSTrustTestUtils.getTestSetup(WSTrustBearerTestCase.class,
- "jaxws-samples-wsse-policy-trust-client.jar jaxws-samples-wsse-policy-trust-sts-bearer.war jaxws-samples-wsse-policy-trust-bearer.war");
+ DeploymentArchives.CLIENT_JAR + " " + DeploymentArchives.STS_BEARER_WAR + " " + DeploymentArchives.SERVER_BEARER_WAR);
// setup the https connector in the server config file.
Map<String, String> sslOptions = new HashMap<String, String>();
10 years, 4 months
JBossWS SVN: r18819 - in stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic: sign-encrypt/META-INF and 1 other directory.
by jbossws-commits@lists.jboss.org
Author: asoldano
Date: 2014-07-28 10:20:29 -0400 (Mon, 28 Jul 2014)
New Revision: 18819
Modified:
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/gcm/WEB-INF/jaxws-endpoint-config.xml
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/sign-encrypt/META-INF/jaxws-client-config.xml
Log:
[JBWS-3789] Streaming ws-security coverage for GCM algorithms tests
Modified: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/gcm/WEB-INF/jaxws-endpoint-config.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/gcm/WEB-INF/jaxws-endpoint-config.xml 2014-07-28 12:32:20 UTC (rev 18818)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/gcm/WEB-INF/jaxws-endpoint-config.xml 2014-07-28 14:20:29 UTC (rev 18819)
@@ -22,6 +22,10 @@
<property-value>alice</property-value>
</property>
<property>
+ <property-name>ws-security.enable.streaming</property-name>
+ <property-value>true</property-value>
+ </property>
+ <property>
<property-name>ws-security.callback-handler</property-name>
<property-value>org.jboss.test.ws.jaxws.samples.wsse.policy.basic.KeystorePasswordCallback</property-value>
</property>
Modified: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/sign-encrypt/META-INF/jaxws-client-config.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/sign-encrypt/META-INF/jaxws-client-config.xml 2014-07-28 12:32:20 UTC (rev 18818)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/samples/wsse/policy/basic/sign-encrypt/META-INF/jaxws-client-config.xml 2014-07-28 14:20:29 UTC (rev 18819)
@@ -22,6 +22,10 @@
<property-value>bob</property-value>
</property>
<property>
+ <property-name>ws-security.enable.streaming</property-name>
+ <property-value>true</property-value>
+ </property>
+ <property>
<property-name>ws-security.callback-handler</property-name>
<property-value>org.jboss.test.ws.jaxws.samples.wsse.policy.basic.KeystorePasswordCallback</property-value>
</property>
10 years, 4 months
JBossWS SVN: r18818 - in stack/cxf/trunk/modules/resources/src/main/resources/modules: wildfly800/org/apache/ws/security/main and 2 other directories.
by jbossws-commits@lists.jboss.org
Author: asoldano
Date: 2014-07-28 08:32:20 -0400 (Mon, 28 Jul 2014)
New Revision: 18818
Modified:
stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/santuario/xmlsec/main/module.xml
stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/ws/security/main/module.xml
stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/santuario/xmlsec/main/module.xml
stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/ws/security/main/module.xml
Log:
[JBWS-3789] Adding required dependencies
Modified: stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/santuario/xmlsec/main/module.xml
===================================================================
--- stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/santuario/xmlsec/main/module.xml 2014-07-28 09:02:36 UTC (rev 18817)
+++ stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/santuario/xmlsec/main/module.xml 2014-07-28 12:32:20 UTC (rev 18818)
@@ -39,6 +39,7 @@
<dependencies>
<module name="javax.api" />
<module name="org.apache.commons.logging" />
+ <module name="org.apache.commons.codec" />
<module name="org.apache.xalan" />
<module name="org.slf4j" />
<module name="javax.xml.bind.api" services="import"/>
Modified: stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/ws/security/main/module.xml
===================================================================
--- stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/ws/security/main/module.xml 2014-07-28 09:02:36 UTC (rev 18817)
+++ stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly800/org/apache/ws/security/main/module.xml 2014-07-28 12:32:20 UTC (rev 18818)
@@ -29,6 +29,8 @@
<dependencies>
<module name="javax.api" />
+ <module name="javax.xml.bind.api" services="import"/>
+ <module name="com.sun.xml.bind" services="import"/>
<module name="javax.xml.rpc.api" />
<module name="org.apache.commons.codec" />
<module name="org.apache.commons.logging" />
Modified: stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/santuario/xmlsec/main/module.xml
===================================================================
--- stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/santuario/xmlsec/main/module.xml 2014-07-28 09:02:36 UTC (rev 18817)
+++ stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/santuario/xmlsec/main/module.xml 2014-07-28 12:32:20 UTC (rev 18818)
@@ -39,6 +39,7 @@
<dependencies>
<module name="javax.api" />
<module name="org.apache.commons.logging" />
+ <module name="org.apache.commons.codec" />
<module name="org.apache.xalan" />
<module name="org.slf4j" />
<module name="javax.xml.bind.api" services="import"/>
Modified: stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/ws/security/main/module.xml
===================================================================
--- stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/ws/security/main/module.xml 2014-07-28 09:02:36 UTC (rev 18817)
+++ stack/cxf/trunk/modules/resources/src/main/resources/modules/wildfly900/org/apache/ws/security/main/module.xml 2014-07-28 12:32:20 UTC (rev 18818)
@@ -29,6 +29,8 @@
<dependencies>
<module name="javax.api" />
+ <module name="javax.xml.bind.api" services="import"/>
+ <module name="com.sun.xml.bind" services="import"/>
<module name="javax.xml.rpc.api" />
<module name="org.apache.commons.codec" />
<module name="org.apache.commons.logging" />
10 years, 4 months
JBossWS SVN: r18817 - stack/cxf/trunk/modules/testsuite.
by jbossws-commits@lists.jboss.org
Author: asoldano
Date: 2014-07-28 05:02:36 -0400 (Mon, 28 Jul 2014)
New Revision: 18817
Modified:
stack/cxf/trunk/modules/testsuite/pom.xml
Log:
[JBWS-3816] Temporarly excluding test
Modified: stack/cxf/trunk/modules/testsuite/pom.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/pom.xml 2014-07-25 21:10:45 UTC (rev 18816)
+++ stack/cxf/trunk/modules/testsuite/pom.xml 2014-07-28 09:02:36 UTC (rev 18817)
@@ -695,6 +695,9 @@
<!-- # [JBWS-3620] Authentication failures w/ Undertow -->
<exclude>org/jboss/test/ws/jaxws/cxf/httpauth/HelloDigestTestCase*</exclude>
+ <!-- # [JBWS-3816] WSTrustActAsTestCase.testActAs failing with move to cxf 3.0.2-SNAPSHOT -->
+ <exclude>org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustActAsTestCase*</exclude>
+
<!-- Manually setup KDC before run this test-->
<exclude>org/jboss/test/ws/jaxws/samples/wsse/kerberos/*TestCase*</exclude>
</excludes>
@@ -780,6 +783,9 @@
<!-- # [JBWS-3620] Authentication failures w/ Undertow -->
<exclude>org/jboss/test/ws/jaxws/cxf/httpauth/HelloDigestTestCase*</exclude>
+ <!-- # [JBWS-3816] WSTrustActAsTestCase.testActAs failing with move to cxf 3.0.2-SNAPSHOT -->
+ <exclude>org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustActAsTestCase*</exclude>
+
<!-- Manually setup KDC before run this test-->
<exclude>org/jboss/test/ws/jaxws/samples/wsse/kerberos/*TestCase*</exclude>
</excludes>
@@ -866,6 +872,9 @@
<!-- # [JBWS-3620] Authentication failures w/ Undertow -->
<exclude>org/jboss/test/ws/jaxws/cxf/httpauth/HelloDigestTestCase*</exclude>
+ <!-- # [JBWS-3816] WSTrustActAsTestCase.testActAs failing with move to cxf 3.0.2-SNAPSHOT -->
+ <exclude>org/jboss/test/ws/jaxws/samples/wsse/policy/trust/WSTrustActAsTestCase*</exclude>
+
<!-- Manually setup KDC before run this test-->
<exclude>org/jboss/test/ws/jaxws/samples/wsse/kerberos/*TestCase*</exclude>
</excludes>
10 years, 4 months
JBossWS SVN: r18816 - in stack/cxf/trunk/modules/testsuite/cxf-tests/src/test: java/org/jboss/test/ws/jaxws/cxf/jbws3809 and 4 other directories.
by jbossws-commits@lists.jboss.org
Author: rsearls
Date: 2014-07-25 17:10:45 -0400 (Fri, 25 Jul 2014)
New Revision: 18816
Added:
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/BasicEjb.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbPortComponentUri.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebContext.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceDupServicename.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceNoServicename.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceProvider.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceServicename.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/JBWS3809TestCase.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/dups/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/dups/EjbWebServiceNoServicename.java
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/ejb-jar.xml
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/jboss-webservices.xml
Log:
[JBWS-3809] added tests to testsuite
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/BasicEjb.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/BasicEjb.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/BasicEjb.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,14 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import javax.jws.WebParam;
+import javax.jws.WebService;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(
+ targetNamespace = "http://org.jboss.ws.test")
+public interface BasicEjb {
+ String getStr (String str);
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbPortComponentUri.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbPortComponentUri.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbPortComponentUri.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,21 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(
+ portName = "EjbPortComponentUriServicePort",
+ targetNamespace = "http://org.jboss.ws.test")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+public class EjbPortComponentUri implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return this.getClass().getSimpleName() + ": " + str;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebContext.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebContext.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebContext.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,25 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import org.jboss.ws.api.annotation.WebContext;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(
+ portName = "EjbWebContextServicePort",
+ targetNamespace = "http://org.jboss.ws.test")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+@WebContext(urlPattern="MyEjbWebContext")
+public class EjbWebContext implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return this.getClass().getSimpleName() + ": " + str;
+ }
+}
+
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceDupServicename.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceDupServicename.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceDupServicename.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,22 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(
+ portName = "EjbWebServiceDupServicenameServicePort",
+ targetNamespace = "http://org.jboss.ws.test",
+ serviceName = "ServicenameEjbWebService")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+public class EjbWebServiceDupServicename implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return this.getClass().getSimpleName() + ": " + str;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceNoServicename.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceNoServicename.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceNoServicename.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,21 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(name = "MyEjbWebServiceNoServicenameService",
+ portName = "EjbWebServiceNoServicenameServicePort",
+ targetNamespace = "http://org.jboss.ws.test")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+public class EjbWebServiceNoServicename implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return this.getClass().getSimpleName() + ": " + str;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceProvider.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceProvider.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceProvider.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,22 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.soap.SOAPBinding;
+import javax.xml.ws.WebServiceProvider;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebServiceProvider(
+ portName = "EjbWebServiceProviderServicePort",
+ targetNamespace = "http://org.jboss.ws.test",
+ serviceName="MyEjbWebServiceProvider")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+public class EjbWebServiceProvider implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return this.getClass().getSimpleName() + ": " + str;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceServicename.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceServicename.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/EjbWebServiceServicename.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,22 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(
+ portName = "EjbWebServiceServicenameServicePort",
+ targetNamespace = "http://org.jboss.ws.test",
+ serviceName = "ServicenameEjbWebService")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+public class EjbWebServiceServicename implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return this.getClass().getSimpleName() + ": " + str;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/JBWS3809TestCase.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/JBWS3809TestCase.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/JBWS3809TestCase.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,142 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809;
+
+import junit.framework.Test;
+import org.jboss.shrinkwrap.api.asset.FileAsset;
+import org.jboss.wsf.test.JBossWSTest;
+import org.jboss.wsf.test.JBossWSTestHelper;
+import org.jboss.wsf.test.JBossWSTestSetup;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Service;
+import java.io.File;
+import java.net.URL;
+import java.util.LinkedList;
+import java.util.List;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+public class JBWS3809TestCase extends JBossWSTest
+{
+ private final String WEB_CONTEXT = "jaxws-cxf-jbws3809";
+
+ public static JBossWSTestHelper.BaseDeployment<?>[] createDeployments() {
+
+ List<JBossWSTestHelper.BaseDeployment<?>> list = new LinkedList<JBossWSTestHelper.BaseDeployment<?>>();
+ list.add(new JBossWSTestHelper.JarDeployment("jaxws-cxf-jbws3809.jar") { {
+ archive
+ .addManifest()
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.EjbPortComponentUri.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebContext.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceNoServicename.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.dups.EjbWebServiceNoServicename.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceServicename.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceDupServicename.class)
+ .addClass(org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceProvider.class)
+ .add(new FileAsset(new File(JBossWSTestHelper.getTestResourcesDir() +
+ "/jaxws/cxf/jbws3809/META-INF/jboss-webservices.xml")),
+ "META-INF/jboss-webservices.xml")
+ .add(new FileAsset(new File(JBossWSTestHelper.getTestResourcesDir() +
+ "/jaxws/cxf/jbws3809/META-INF/ejb-jar.xml")),
+ "META-INF/ejb-jar.xml")
+ ;
+ }
+ });
+
+ return list.toArray(new JBossWSTestHelper.BaseDeployment<?>[list.size()]);
+ }
+
+ public static Test suite()
+ {
+ return new JBossWSTestSetup(JBWS3809TestCase.class,
+ JBossWSTestHelper.writeToFile(createDeployments()));
+ }
+
+ public void testEjbPortComponentUri() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "EjbPortComponentUriService");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/MyEjbPortComponentUri?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("EjbPortComponentUri: confirmed", proxy.getStr("confirmed"));
+ }
+
+ public void testEjbWebContext() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "EjbWebContextService");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/MyEjbWebContext?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("EjbWebContext: confirmed", proxy.getStr("confirmed"));
+ }
+
+ public void testEjbWebServiceNoServicename() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "EjbWebServiceNoServicenameService");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/MyEjbWebServiceNoServicenameService?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("EjbWebServiceNoServicename: confirmed", proxy.getStr("confirmed"));
+ }
+
+ public void testDupEjbWebServiceNoServicename() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "EjbWebServiceNoServicenameService");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/MyDupEjbWebServiceNoServicenameService?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("DupEjbWebServiceNoServicename: confirmed", proxy.getStr("confirmed"));
+ }
+
+ public void testEjbWebServiceServicename() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "ServicenameEjbWebService");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/ServicenameEjbWebService/EjbWebServiceServicename?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("EjbWebServiceServicename: confirmed", proxy.getStr("confirmed"));
+ }
+
+ public void testEjbWebServiceDupServicename() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "ServicenameEjbWebService");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/ServicenameEjbWebService/EjbWebServiceDupServicename?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("EjbWebServiceDupServicename: confirmed", proxy.getStr("confirmed"));
+ }
+
+
+ public void testEjbWebServiceProvider() throws Exception
+ {
+ QName serviceName = new QName("http://org.jboss.ws.test", "MyEjbWebServiceProvider");
+ URL wsdlURL = new URL("http://" + getServerHost() + ":8080/"
+ + WEB_CONTEXT + "/EjbWebServiceProvider?wsdl");
+
+ Service service = Service.create(wsdlURL, serviceName);
+ BasicEjb proxy = (BasicEjb)service.getPort(BasicEjb.class);
+
+ assertEquals("EjbWebServiceProvider: confirmed", proxy.getStr("confirmed"));
+ }
+
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/dups/EjbWebServiceNoServicename.java
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/dups/EjbWebServiceNoServicename.java (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/cxf/jbws3809/dups/EjbWebServiceNoServicename.java 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,23 @@
+package org.jboss.test.ws.jaxws.cxf.jbws3809.dups;
+
+import org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb;
+
+import javax.jws.WebMethod;
+import javax.jws.WebParam;
+import javax.jws.WebService;
+import javax.jws.soap.SOAPBinding;
+
+/**
+ * User: rsearls
+ * Date: 7/25/14
+ */
+@WebService(name = "MyDupEjbWebServiceNoServicenameService",
+ portName = "DupEjbWebServiceNoServicenameServicePort",
+ targetNamespace = "http://org.jboss.ws.test")
+@SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
+public class EjbWebServiceNoServicename implements BasicEjb {
+ @WebMethod(operationName = "getStr")
+ public String getStr (@WebParam(name = "str") String str) {
+ return "Dup" + this.getClass().getSimpleName() + ": " + str;
+ }
+}
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/ejb-jar.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/ejb-jar.xml (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/ejb-jar.xml 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,94 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
+ http://java.sun.com/xml/ns/javaee/ejb-jar_3_1.xsd"
+ version="3.1">
+
+ <enterprise-beans>
+
+ <session id="EjbPortComponentUriServiceBean">
+ <display-name>EjbPortComponentUriServiceBean</display-name>
+ <ejb-name>EjbPortComponentUriServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>org.jboss.test.ws.jaxws.cxf.jbws3809.EjbPortComponentUri
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <session id="EjbWebContextServiceBean">
+ <display-name>EjbWebContextServiceBean</display-name>
+ <ejb-name>EjbWebContextServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebContext
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+
+ <session id="EjbWebServiceNoServicenameServiceBean">
+ <display-name>EjbWebServiceNoServicenameServiceBean</display-name>
+ <ejb-name>EjbWebServiceNoServicenameServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>
+ org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceNoServicename
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <session id="DupEjbWebServiceNoServicenameServiceBean">
+ <display-name>DupEjbWebServiceNoServicenameServiceBean</display-name>
+ <ejb-name>DupEjbWebServiceNoServicenameServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>
+ org.jboss.test.ws.jaxws.cxf.jbws3809.dups.EjbWebServiceNoServicename
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <session id="EjbWebServiceServicenameServiceBean">
+ <display-name>EjbWebServiceServicenameServiceBean</display-name>
+ <ejb-name>EjbWebServiceServicenameServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>
+ org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceServicename
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <session id="EjbWebServiceDupServicenameServiceBean">
+ <display-name>EjbWebServiceDupServicenameServiceBean</display-name>
+ <ejb-name>EjbWebServiceDupServicenameServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>
+ org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceDupServicename
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ <session id="EjbWebServiceProviderServiceBean">
+ <display-name>EjbWebServiceProviderServiceBean</display-name>
+ <ejb-name>EjbWebServiceProviderServiceBean</ejb-name>
+ <business-local>org.jboss.test.ws.jaxws.cxf.jbws3809.BasicEjb
+ </business-local>
+ <ejb-class>org.jboss.test.ws.jaxws.cxf.jbws3809.EjbWebServiceProvider
+ </ejb-class>
+ <session-type>Stateless</session-type>
+ <transaction-type>Container</transaction-type>
+ </session>
+
+ </enterprise-beans>
+
+</ejb-jar>
\ No newline at end of file
Added: stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/jboss-webservices.xml
===================================================================
--- stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/jboss-webservices.xml (rev 0)
+++ stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/resources/jaxws/cxf/jbws3809/META-INF/jboss-webservices.xml 2014-07-25 21:10:45 UTC (rev 18816)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<webservices version="1.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns="http://www.jboss.com/xml/ns/javaee"
+ xsi:schemalocation="http://www.jboss.com/xml/ns/javaee
+ http://www.jboss.org/j2ee/schema/jboss_webservices_1_0.xsd">
+
+ <port-component>
+ <ejb-name>EjbPortComponentUriServiceBean</ejb-name>
+ <port-component-uri>MyEjbPortComponentUri</port-component-uri>
+ </port-component>
+</webservices>
\ No newline at end of file
10 years, 5 months
JBossWS SVN: r18815 - stack/cxf/trunk.
by jbossws-commits@lists.jboss.org
Author: asoldano
Date: 2014-07-25 09:45:21 -0400 (Fri, 25 Jul 2014)
New Revision: 18815
Modified:
stack/cxf/trunk/pom.xml
Log:
Move to Apache CXF 3.0.2-SNAPSHOT and WSS4J 2.0.2-SNAPSHOT
Modified: stack/cxf/trunk/pom.xml
===================================================================
--- stack/cxf/trunk/pom.xml 2014-07-23 22:03:45 UTC (rev 18814)
+++ stack/cxf/trunk/pom.xml 2014-07-25 13:45:21 UTC (rev 18815)
@@ -71,7 +71,7 @@
<wildfly810.version>8.1.0.Final</wildfly810.version>
<wildfly900.version>9.0.0.Alpha1-SNAPSHOT</wildfly900.version>
<ejb.api.version>1.0.2.Final</ejb.api.version>
- <cxf.version>3.0.1</cxf.version>
+ <cxf.version>3.0.2-SNAPSHOT</cxf.version>
<cxf.asm.version>3.3.1</cxf.asm.version>
<cxf.xjcplugins.version>2.7.0</cxf.xjcplugins.version>
<jboss.common.core.version>2.2.17.GA</jboss.common.core.version>
@@ -102,7 +102,7 @@
<velocity.version>1.7</velocity.version>
<xerces.version>2.9.1</xerces.version>
<xmlsec.version>2.0.1</xmlsec.version>
- <wss4j.version>2.0.1</wss4j.version>
+ <wss4j.version>2.0.2-SNAPSHOT</wss4j.version>
<wstx.version>4.2.0</wstx.version>
<spring.version>3.2.8.RELEASE</spring.version>
<shrinkwrap.version>1.1.3</shrinkwrap.version>
10 years, 5 months