From c3e4497efdb86d5e3bf3c661be53ac13ffb73ebe Mon Sep 17 00:00:00 2001 From: ajay priyadarshi Date: Thu, 15 Feb 2018 13:43:39 +0530 Subject: [PATCH] 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 --- .../onap/vfc/nfvo/emsdriver/northbound/client/HttpClientFactory.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) 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; -- 2.16.6