ks = loadKeyStore(passphrase);
} catch (KeyStoreException e) { // Problem loading keystore
log4j.error(e.getMessage(), e);
}
// check if the Certificate for alias is installed. If not, install it.
if (ks != null && !ks.containsAlias(alias)) {
installCert(url, alias, passphrase);
ks = loadKeyStore(passphrase);
}
// Now try and establish the secure connection
try {