• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

Error in Calling Web service Through SSL

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am Trying to call a web service Client in my code but it gives following error



My Code is As follows
web service call ...

 
Nilu Deshmukh
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I searched through google and found that its issue in Certificate installation..
can any one tell me how to install a certificate in trustore.

Thanks in Advance..
 
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
I have a step-by-step guide on how to set up certificates for ordinary SSL and mutual authentication in my SCDJWS study notes, which you can find here: http://faq.javaranch.com/content/Exam-Objectives-5.pdf
Take a look at section 8.3. Hope this is of any help!
Best wishes!
 
Nilu Deshmukh
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks For Yor Help.

I came to new the Problem. The Prblem is in Java keystore. JDK is not able to load the keystore. that why i can call the web service through browser https. but not through my code..

So Please Tell me how to load the certificat in JDK or do I need to set any Security Policy for my code....

Becase when I check the system Property through java code... it gives null.

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I run in this problem in an Jboss with some EARs previously deployed, after a lot of test I realize that the problem was the the System/ssl variables set by other EAR, so the fix is remove ssl properties before invoke Axis.


 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I found some resource in http://www.longhowl.com/howls/144
 
Greenhorn
Posts: 2
Android Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think that: I got the final solution to this issue:

Properties p = System.getProperties();
System.getProperties().put("javax.net.ssl.trustStore", "C:/Documents and Settings/rc3570/.keystore");
System.getProperties().put("javax.net.ssl.trustStorePassword", "password");
WelcomeTestImplServiceLocator welcomeTestImplServiceLocator = new WelcomeTestImplServiceLocator();
WelcomeTest welcomeTest = welcomeTestImplServiceLocator.getWelcomeTestImplPort();
// to use Basic HTTP Authentication:
((Stub)welcomeTest)._setProperty(Call.USERNAME_PROPERTY, "admin");
((Stub)welcomeTest)._setProperty(Call.PASSWORD_PROPERTY, "password");
System.out.println(welcomeTest.getWelcomeTestStringWithName("jitao"));

Note: before build the client, need to create ./keystore
 
Run away! Run away! Here, take this tiny ad with you:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic