public static String getExistingTrustRootPath() {
        String str2 = System.getenv("GLOBUS_LOCATION");
        if (str2 == null) {
            str2 = System.getProperty("GLOBUS_LOCATION");
        }
        String str1 = System.getenv("X509_CERT_DIR");
        if (str1 == null) {
            str1 = System.getProperty("X509_CERT_DIR");
        }
        if (str1 == null) {
            str1 = getDir(System.getProperty("user.home")
                    + "/.globus/certificates");
        }
        if (str1 == null) {
            str1 = getDir("/etc/grid-security/certificates");
        }
        if (str1 == null) {
            str1 = getDir(str2 + File.separator + "share" + File.separator
                    + "certificates");
        }
        return str1;
    }