reverted over-reaching check on webfinger fetcher

pull/820/merge
Justin Richer 2015-06-26 17:17:38 -04:00
parent cd47d32e2d
commit 667c766273
1 changed files with 6 additions and 8 deletions

View File

@ -208,14 +208,12 @@ public class WebfingerIssuerService implements IssuerService {
// preserving http scheme is strictly for demo system use only.
String scheme = key.getScheme();
if (!Strings.isNullOrEmpty(scheme)) {
if (scheme.equals("http")) {
if (forceHttps) {
throw new IllegalArgumentException("Scheme must start with htps");
} else {
logger.warn("Webfinger endpoint MUST use the https URI scheme, overriding by configuration");
scheme = "http://"; // add on colon and slashes.
}
if (!Strings.isNullOrEmpty(scheme) &&scheme.equals("http")) {
if (forceHttps) {
throw new IllegalArgumentException("Scheme must start with htps");
} else {
logger.warn("Webfinger endpoint MUST use the https URI scheme, overriding by configuration");
scheme = "http://"; // add on colon and slashes.
}
} else {
scheme = "https://";