|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.geronimo.security.realm.providers.RepeatedFailureLockoutLoginModule
public class RepeatedFailureLockoutLoginModule
Tracks the number of recent login failures for each user, and starts rejecting login attemps if the number of failures in a certain period for a particular user gets too high. The period, number of failures, and lockout duration are configurable, but default to 5 failures in 5 minutes cause all subsequent attemps to fail for 30 minutes. This module does not write any Principals into the Subject. To enable this login module, set your primary login module and any other login modules to REQUIRED or OPTIONAL, and list this module in last place, set to REQUISITE. The parameters used by this module are:
Field Summary | |
---|---|
static String |
FAILURE_COUNT_OPTION
|
static String |
FAILURE_PERIOD_OPTION
|
static String |
LOCKOUT_DURATION_OPTION
|
Constructor Summary | |
---|---|
RepeatedFailureLockoutLoginModule()
|
Method Summary | |
---|---|
boolean |
abort()
Notes that (and when) a login failure occured, used to calculate whether the user should be locked out. |
boolean |
commit()
This module does nothing if a login succeeds. |
void |
initialize(Subject subject,
CallbackHandler callbackHandler,
Map sharedState,
Map options)
Reads the configuration settings for this module. |
boolean |
login()
Checks whether the user should be or has been locked out. |
boolean |
logout()
This module does nothing on a logout. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String FAILURE_COUNT_OPTION
public static final String FAILURE_PERIOD_OPTION
public static final String LOCKOUT_DURATION_OPTION
Constructor Detail |
---|
public RepeatedFailureLockoutLoginModule()
Method Detail |
---|
public void initialize(Subject subject, CallbackHandler callbackHandler, Map sharedState, Map options)
initialize
in interface LoginModule
public boolean login() throws LoginException
login
in interface LoginModule
LoginException
public boolean commit() throws LoginException
commit
in interface LoginModule
LoginException
public boolean abort() throws LoginException
abort
in interface LoginModule
LoginException
public boolean logout() throws LoginException
logout
in interface LoginModule
LoginException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |