You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Abid Hussain <hu...@inf.fu-berlin.de> on 2007/11/07 11:04:30 UTC
client https and server http
Hi everybody,
I have the following problem:
My web application contains
- a Web Service and
- a client (which calls another Web Service).
The client calls the remote service using https whereas the service
deployed in my application should use http.
I have configured the service as following:
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:jaxws="http://cxf.apache.org/jaxws"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://cxf.apache.org/jaxws
http://cxf.apache.org/schemas/jaxws.xsd">
<import resource="classpath:META-INF/cxf/cxf.xml" />
<import resource="classpath:META-INF/cxf/cxf-extension-soap.xml" />
<import resource="classpath:META-INF/cxf/cxf-servlet.xml" />
<jaxws:endpoint id="moduleServiceImpl"
implementor="modulverwaltung.service.ModuleServiceImpl"
address="/ModuleService" />
</beans>
I did the clients's https configuration in the program code:
Client client = ClientProxy.getClient(port);
HTTPConduit conduit = (HTTPConduit) client.getConduit();
TLSClientParameters tlsParams = new TLSClientParameters();
conduit.setTlsClientParameters(tlsParams);
When I try to call the remote service from my client, the following happens:
INFO: Interceptor has thrown exception, unwinding now
org.apache.cxf.interceptor.Fault: Could not send Message.
at
org.apache.cxf.interceptor.MessageSenderInterceptor.handleMessage(MessageSenderInterceptor.java:48)
at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254)
at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205)
at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
at org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)
at $Proxy33.getLecturers(Unknown Source)
at
kvv.service.client.KvvServiceClient.getLecturers(KvvServiceClient.java:74)
at
modulverwaltung.tools.AdaptLecturersToKvv.main(AdaptLecturersToKvv.java:29)
Caused by: java.io.IOException: Illegal Protocol http for HTTPS
URLConnection Factory.
at
org.apache.cxf.transport.https.HttpsURLConnectionFactory.createConnection(HttpsURLConnectionFactory.java:124)
at org.apache.cxf.transport.http.HTTPConduit.prepare(HTTPConduit.java:475)
at
org.apache.cxf.interceptor.MessageSenderInterceptor.handleMessage(MessageSenderInterceptor.java:46)
... 8 more
Would be thankful for any help...
Best regards,
Abid Hussain
--
Abid Hussain
Mail: hussain@inf.fu-berlin.de
Tel.: 0179 / 9080412
Web: http://www.abid76.de