Only enable auth.allowGoogleAccountUpgrade when auth.type = OpenID
Any other time this setting should always be false. Change-Id: Ia590a07c8abf786ca204579409e6912c015dc42b Signed-off-by: Shawn O. Pearce <sop@google.com>
This commit is contained in:
@@ -61,8 +61,12 @@ public class AuthConfig {
|
|||||||
anonymousGroups = Collections.singleton(s.anonymousGroupId);
|
anonymousGroups = Collections.singleton(s.anonymousGroupId);
|
||||||
administratorGroup = s.adminGroupId;
|
administratorGroup = s.adminGroupId;
|
||||||
|
|
||||||
allowGoogleAccountUpgrade =
|
if (loginType == AuthType.OPENID) {
|
||||||
cfg.getBoolean("auth", "allowgoogleaccountupgrade", false);
|
allowGoogleAccountUpgrade =
|
||||||
|
cfg.getBoolean("auth", "allowgoogleaccountupgrade", false);
|
||||||
|
} else {
|
||||||
|
allowGoogleAccountUpgrade = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private String[] toTrusted(final Config cfg) {
|
private String[] toTrusted(final Config cfg) {
|
||||||
|
|||||||
Reference in New Issue
Block a user