// put the server certificate, if available, in the configuration
X509Certificate x509ServerCertificate = (X509Certificate) props.get(PipeConstants.SERVER_CERT);
// and make sure the validition of the server certificate happens only once
if (x509ServerCertificate != null) {
if (isCertValidityVerified == false) {
CertificateRetriever cr = new CertificateRetriever();
isCertValid = cr.setServerCertInTheSTSConfig(config, secEnv, x509ServerCertificate);
cr = null;
isCertValidityVerified = true;
} else {
if (isCertValid == true) {
config.getOtherOptions().put("Identity", x509ServerCertificate);