diff options
Diffstat (limited to 'optical-service')
-rw-r--r-- | optical-service/provider/src/main/java/org/onap/sdnc/northbound/asyncrequests/SdncOdlConnection.java | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/optical-service/provider/src/main/java/org/onap/sdnc/northbound/asyncrequests/SdncOdlConnection.java b/optical-service/provider/src/main/java/org/onap/sdnc/northbound/asyncrequests/SdncOdlConnection.java index 860e84bb..accdb4e9 100644 --- a/optical-service/provider/src/main/java/org/onap/sdnc/northbound/asyncrequests/SdncOdlConnection.java +++ b/optical-service/provider/src/main/java/org/onap/sdnc/northbound/asyncrequests/SdncOdlConnection.java @@ -32,6 +32,7 @@ import javax.net.ssl.HostnameVerifier; import javax.net.ssl.HttpsURLConnection; import javax.net.ssl.SSLSession; import org.apache.commons.codec.binary.Base64; +import org.onap.ccsdk.sli.core.utils.common.AcceptIpAddressHostNameVerifier; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -105,12 +106,7 @@ public class SdncOdlConnection { httpConn.setUseCaches(false); if (httpConn instanceof HttpsURLConnection) { - HostnameVerifier hostnameVerifier = new HostnameVerifier() { - @Override - public boolean verify(String hostname, SSLSession session) { - return true; - } - }; + HostnameVerifier hostnameVerifier = new AcceptIpAddressHostNameVerifier(); ((HttpsURLConnection) httpConn).setHostnameVerifier(hostnameVerifier); } |