File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services and the fly likes Consuming secured WCF service Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Consuming secured WCF service" Watch "Consuming secured WCF service" New topic
Author

Consuming secured WCF service

Boris Belovic
Greenhorn

Joined: Nov 27, 2009
Posts: 14
Hello,
I am trying to consume secured WCF service. I am trying to consume it using Netbeans IDE. Its WSDL contains <X509Certificate> elements, which contains Base64 encoded certificate. I cropped this certificate into separate file and imported it into truststore.

My client uses username and password authentication, so i filled in valid username and password and I refer to my truststore from WSDL file. BUt when I try to run my client, I got following exception:

INFO: WSP5018: Loaded WSIT configuration from file: file:/C:/Users/belovic/Documents/NetBeansProjects/ETR3/build/classes/META-INF/wsit-client.xml.
account info for cos1
15.11.2012 10:50:28 com.sun.xml.wss.impl.misc.DefaultCallbackHandler$X509CertificateValidatorImpl validate
SEVERE: WSS1533: Validation of self signed certificate failed.
15.11.2012 10:50:28 com.sun.xml.wss.jaxws.impl.SecurityClientTube processRequest
WARNING: Could not validate the the server certificate


Here is relevant part of svc.xml document with reference to truststore


I am also attaching jax-ws.xml


and wsit-client.xml


I don't know why the certificate is refused?
Bob Scott
Ranch Hand

Joined: Oct 04, 2012
Posts: 40

You might try using the MakeCert tool. I don't know if this will solve your problem but I played around with this awhile back and seem to remember using it. Hope this helps.

MakeCert Tool

EDIT: After looking at this further, what I told you won't do it but there is some documentation links on the left side of the page that I referenced that might help you out.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Consuming secured WCF service
 
Similar Threads
Help with SAML Sender vouches with a JAXWS Web Service and IBM Websphere please
Add SAML Sender-vouches assertion to SOAP Header on WebService(WebSphere)
What's wrong with my WSDL ?
Uisng Message Level Security for JAX WS Web services deployed unde Weblogic 10
Https and wsdl