}
if (session == null) {
throw new IOException("No SSLSession detected");
}
}
HostnameVerifier verifier;
if (tlsClientParameters.isUseHttpsURLConnectionDefaultHostnameVerifier()) {
verifier = HttpsURLConnection.getDefaultHostnameVerifier();
} else if (tlsClientParameters.isDisableCNCheck()) {
verifier = CertificateHostnameVerifier.ALLOW_ALL;
} else {
verifier = CertificateHostnameVerifier.DEFAULT;
}
if (!verifier.verify(url.getHost(), session)) {
throw new IOException("Could not verify host " + url.getHost());
}
String method = (String)outMessage.get(Message.HTTP_REQUEST_METHOD);
String cipherSuite = null;