if (conf == null)
{
return;
}
SecurityDomain securityDomainConf = conf.getSecurityDomain();
if (securityDomainConf != null)
{
JAASSecurityDomainAdaptorResolver sdResolver = (JAASSecurityDomainAdaptorResolver)ServiceLoader.loadService(JAASSecurityDomainAdaptorResolver.class.getName(),
null);
if (sdResolver == null)
{
throw new WSSecurityException("Could not get a jaas security domain resolver implementation implementing " + JAASSecurityDomainAdaptorResolver.class
+ "; this is container specific, so please check your classpath is properly set if running on client side.");
}
try
{
sd = sdResolver.lookup(securityDomainConf.getJndi());
}
catch (Exception e)
{
throw new WSSecurityException("JNDI failure handling " + securityDomainConf.getJndi(), e);
}
// if we reached this point, means we have a JNDI name pointing to a valid JAAS Security Domain
keyStore = sd.getKeyStore();
trustStore = sd.getTrustStore();
securityDomainAuthToken = securityDomainConf.getAuthToken();
useSecurityDomainAliases = securityDomainConf.isUseSecurityDomainAliases();
}
else
{
URL keyStoreURL = conf.getKeyStoreURL();
String keyStoreType = conf.getKeyStoreType();