• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JBoss and certificates

 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I'm having a problem connecting to another server from my JBoss (3.2.3) server. It works fine when I connect from a standalone class, but when I try to do it from JBoss it seems like the certificate can't be found. It's not really the connection that doesn't work, but that the certificate is not used when connecting from within JBoss. I get no error messages from JBoss regarding the certificate, even if I set the logging level to trace. The errormessage I get is from the remote web-service I'm using, and it says that I need a valid certificate...

This is the java code I use to set up the connection in JBoss, it's the same code I successfully run as a standalone client.

System.setProperty("sun.rmi.transport.connectionTimeout", "20000");
System.setProperty("java.protocol.handler.pkgs", "com.sun.net.ssl.internal.www.protocol");
Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
System.setProperty("javax.net.ssl.keyStore", "C:/jboss-3.2.3/server/default/conf/myKeystore.pfx");
System.setProperty("javax.net.ssl.keyStoreType", "pkcs12");
System.setProperty("javax.net.ssl.keyStorePassword", "myPassword");

Why can't I get it to work, do I need to config some jboss xml-files or something?
 
reply
    Bookmark Topic Watch Topic
  • New Topic