private X509Certificate certificate(String certificate) throws Exception {
        return (X509Certificate) CertificateFactory.getInstance("X.509").generateCertificate(
                new ByteArrayInputStream(certificate.getBytes(UTF_8)));
    }
Earlier implementations of Android's hostname verifier required that
wildcard names wouldn't match "*.com" or similar. This was a nonstandard
check that we've since dropped. It is the CA's responsibility to not hand
out certificates that match so broadly.
common/src/test/java/org/conscrypt/HostnameVerifierTest.java