|
From: Pallavidino L. <luc...@gm...> - 2012-09-25 10:01:28
|
Hi,
I've got a problem to access ejba web service through an EJB deploy on
Glassfish.
I use this code :
Properties systemProps = System.getProperties();
systemProps.put("javax.net.ssl.trustStoreType",
props.getProperty("ejbca.truststoretype"));
systemProps.put("javax.net.ssl.trustStore",props.getProperty("ejbca.truststore"));
systemProps.put("javax.net.ssl.trustStorePassword",props.getProperty("ejbca.truststorepass"));
systemProps.put("javax.net.ssl.keyStoreType",
props.getProperty("ejbca.keystoretype"));
systemProps.put("javax.net.ssl.keyStore",props.getProperty("ejbca.keystore"));
systemProps.put("javax.net.ssl.keyStorePassword",props.getProperty("ejbca.storepass"));
System.setProperties(systemProps);
// Initialisation de l'accès aux web services
QName qname = new QName("http://ws.protocol.core.ejbca.org/",
"EjbcaWSService");
EjbcaWSService service = new EjbcaWSService(new URL(urlstr),qname);
EjbcaWS ejbcaraws = service.getEjbcaWSPort();
All is ok, my truststore and my keystore are good (it works in a simple
java project). But in an EJB deploy on Glassfish, I've got an error
(server certificate not trusted).
I've you got an idea to solve this problem please ?
|