Class LoginManagement
java.lang.Object
ecmwf.common.security.LoginManagement
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
Check.static void
Called to check if the password looks good and if it does not: increment the banned counter and delay the answer.static void
clear()
Remove all the hosts from the banned list.static void
Remove the specified host from the banned list.static void
Increment.static boolean
isPasscode
(String passcode) Checks if the password has the right format.
-
Constructor Details
-
LoginManagement
public LoginManagement()
-
-
Method Details
-
clear
public static void clear()Remove all the hosts from the banned list. -
clear
Remove the specified host from the banned list.- Parameters:
host
- the host
-
increment
Increment. Called when there is an error trying to login from this host (e.g. password refused or user not registered). This method only record the error if the login management module is activated.- Parameters:
host
- the host
-
check
Check. Called before to start the login process to make sure this host is not already banned.- Parameters:
host
- the host- Returns:
- true, if successful
-
isPasscode
Checks if the password has the right format.- Parameters:
passcode
- the passcode- Returns:
- true, if it looks like a valid passcode
-
check
Called to check if the password looks good and if it does not: increment the banned counter and delay the answer.- Parameters:
host
- the hostuser
- the userpasscode
- the passcode- Throws:
EccmdException
- the eccmd exception
-