private static String contactUrl(final String addr, final CasSSLContext context) throws Exception {
        val url = new URI(addr).toURL();
        val connection = (HttpsURLConnection) url.openConnection();
        connection.setRequestMethod("GET");
        connection.setHostnameVerifier(NoopHostnameVerifier.INSTANCE);
        connection.setSSLSocketFactory(context.getSslContext().getSocketFactory());
        try (val is = connection.getInputStream()) {
            return IOUtils.toString(is, StandardCharsets.UTF_8);
        }
    }
This is {@link CasSSLContextTests}.

@author Misagh Moayyed
@since 6.4.0
core/cas-server-core-authentication-api/src/test/java/org/apereo/cas/authentication/CasSSLContextTests.java