NIHVIVO-2694 Add methods and an exception to Authenticator, so we can tell when a user is not allowed to login.

This commit is contained in:
j2blake 2012-02-01 22:03:11 +00:00
parent 0a19ed7d86
commit 6986eb6308
12 changed files with 164 additions and 32 deletions

View file

@ -20,7 +20,7 @@ import edu.cornell.mannlib.vitro.webapp.beans.UserAccount;
public class AuthenticatorStub extends Authenticator {
public static final String FACTORY_ATTRIBUTE_NAME = AuthenticatorFactory.class
.getName();
// ----------------------------------------------------------------------
// factory - store this in the context.
//
@ -97,6 +97,11 @@ public class AuthenticatorStub extends Authenticator {
return usersByExternalAuthId.get(externalAuthId);
}
@Override
public boolean isUserPermittedToLogin(UserAccount userAccount) {
return true;
}
@Override
public boolean isCurrentPassword(UserAccount userAccount,
String clearTextPassword) {