Skip to main content

JAXWS: using different SSL certificates

Please note these forums are being decommissioned and use the new and improved forums at
1 reply [Last post]
Joined: 2011-02-16

I need to integrate against two different webservices, both are using SSL certificates to handle security.
The problem is that each webservice has a different SSL certificate and we dont want them to have same.
So, how do i use different SSL certificates against different webservices with JAX-WS?
The way you use SSL certificates today is by setting system properties, and that is no good solution.

I found an old post about this is it still the same?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Joined: 2003-06-14

JAX-WS primarily uses JDK's HttpsURLConnection. There is a property SSL_SOCKET_FACTORY which you can set for each client proxy. This is explained here:

I don't know if there is any better way to do this in GlassFish(if it allows any client side SSL configuration per application)