I got some code from a very helpful Stackoverflow contributor (Michal Foska), and I am having some issues implementing it in a Mobilefirst Adapter. It seems that Mobilefirst picks up the wrong SSLConnectionSocketFactory class which does not have the same constructor as below.
It appears to only allow a X509HostnameVerifier. Any ideas?
SSLConnectionSocketFactory sslCF = new SSLConnectionSocketFactory(context, new HostnameVerifier() {
@Override
public boolean verify(String hostname, SSLSession session) {
// or add your own test here
return true;
}});