private void checkServerDN(X509Certificate paramX509Certificate)
                throws CertificateException {
            String str1 = paramX509Certificate.getSubjectX500Principal()
                    .getName();
            MyProxyLogon.logger.fine("MyProxy server DN: " + str1);
            int i = str1.indexOf("CN=");
            if (i == -1) {
                throw new CertificateException("Server certificate subject ("
                        + str1 + "does not contain a CN component.");
            }
            String str2 = str1.substring(i + 3);
            i = str2.indexOf(',');
            if (i >= 0) {
                str2 = str2.substring(0, i);
            }
            if ((i = str2.indexOf('/')) >= 0) {
                String str3 = str2.substring(0, i);
                str2 = str2.substring(i + 1);
                if ((!str3.equals("host")) && (!str3.equals("myproxy"))) {
                    throw new CertificateException(
                            "Server certificate subject CN contains unknown service element: "
                                    + str1);
                }
            }
            String str3 = MyProxyLogon.this.host;
            if (str3.equals("localhost")) {
                try {
                    str3 = InetAddress.getLocalHost().getHostName();
                } catch (Exception localException) {
                }
            }
            if (!str2.equals(str3)) {
                throw new CertificateException(
                        "Server certificate subject CN (" + str2
                                + ") does not match server hostname ("
                                + MyProxyLogon.this.host + ").");
            }
        }