From: ajay priyadarshi Date: Thu, 15 Feb 2018 08:13:39 +0000 (+0530) Subject: Specified the throwable exception. X-Git-Tag: v1.1.0~49 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F99%2F31799%2F1;p=vfc%2Fnfvo%2Fdriver%2Fems.git Specified the throwable exception. emsdriver/northbound/client/HttpClientFactory.java file name: HttpClientFactory.java Change-Id: I0446258abc20e630c820cc7a9117076ae9dd26da Issue-ID: VFC-760 Signed-off-by: ajay priyadarshi --- diff --git a/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/HttpClientFactory.java b/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/HttpClientFactory.java index 00c1558..bc286fd 100644 --- a/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/HttpClientFactory.java +++ b/ems/boco/src/main/java/org/onap/vfc/nfvo/emsdriver/northbound/client/HttpClientFactory.java @@ -24,6 +24,7 @@ import org.apache.http.ssl.SSLContextBuilder; import javax.net.ssl.SSLContext; import java.security.cert.CertificateException; import java.security.cert.X509Certificate; +import java.security.GeneralSecurityException; /** * HttpClient @@ -31,10 +32,10 @@ import java.security.cert.X509Certificate; public class HttpClientFactory { - public static CloseableHttpClient getSSLClientFactory() throws Exception { + public static CloseableHttpClient getSSLClientFactory() throws GeneralSecurityException { SSLContext sslContext = new SSLContextBuilder().loadTrustMaterial(null, new TrustStrategy() { - //信任所有 + //Trust all public boolean isTrusted(X509Certificate[] chain, String authType) throws CertificateException { return true;