public interface PasswordServiceLocal extends PasswordService
PasswordService| Modifier and Type | Method and Description |
|---|---|
void |
addValidations(org.cyclos.impl.utils.validation.Property property,
BasicUser user,
java.lang.String username,
PasswordType passwordType)
Adds all password validations according to specified password type.
|
Pair<java.lang.String,Password> |
create(BasicUser user,
PasswordType passwordType,
java.lang.String password,
PasswordStatus status)
Creates a password for the given user and password type.
|
boolean |
exists(BasicUser user,
PasswordType passwordType)
Returns whether a valid password exists for the given user / password type
|
java.util.Date |
getExpirationDate(Password password)
Returns the expiration date according to the password's type.
|
Pair<Password,PasswordStatus> |
getPasswordAndStatus(BasicUser user,
PasswordType passwordType)
Returns the status and the password record for the given user and password type.
|
PasswordData |
getPasswordData(BasicUser user,
PasswordType passwordType)
Returns the
PasswordData for the given user and password type. |
PasswordStatus |
getStatus(BasicUser user,
PasswordType type,
boolean forAccess)
Returns current password status for the given user and type.
|
Pair<PasswordStatus,java.util.Set<PasswordAction>> |
getStatusAndActions(BasicUser user,
PasswordType passwordType)
Similar to
PasswordService.getData(org.cyclos.model.users.users.UserLocatorVO), but with fewer data and preventing
calculating the status twice |
boolean |
isPendingSecurityQuestion()
Returns whether the currently authenticated user needs to set a security question
|
boolean |
isUserCanChangePassword(BasicUser user,
PasswordType passwordType)
Returns if the given user can change the password for the given type
|
boolean |
remove(BasicUser user,
PasswordType passwordType)
Removes the password of the given user and type
|
void |
setSecurityQuestion(BasicUser user,
SetSecurityQuestionDTO params)
Sets the securiy question for the given user
|
void |
updateUser(BasicUser user)
Update the redundant password status information on the user
|
activate, allowActivation, change, changeForgottenPassword, disable, enable, forgotPasswordRequest, generateNew, getChangeForgottenPasswordData, getChangePasswordData, getData, getPasswordData, getSetSecurityQuestionData, requestNewOTP, requestNewOTPForSecondaryPassword, reset, resetAndSend, resetSecurityQuestion, setSecurityQuestion, unblockvoid addValidations(org.cyclos.impl.utils.validation.Property property,
BasicUser user,
java.lang.String username,
PasswordType passwordType)
IllegalActionException - When the given password type doesn't apply to the given userPair<java.lang.String,Password> create(BasicUser user, PasswordType passwordType, java.lang.String password, PasswordStatus status)
PasswordStatus.ACTIVE, PasswordStatus.EXPIRED, PasswordStatus.RESET.IllegalActionException - When the given password type doesn't apply to the given user or the password
should be generatedboolean exists(BasicUser user, PasswordType passwordType)
java.util.Date getExpirationDate(Password password)
Pair<Password,PasswordStatus> getPasswordAndStatus(BasicUser user, PasswordType passwordType)
PasswordData getPasswordData(BasicUser user, PasswordType passwordType)
PasswordData for the given user and password type.PasswordStatus getStatus(BasicUser user, PasswordType type, boolean forAccess)
forAccess - if true means the status is used to check access (use with caution)Pair<PasswordStatus,java.util.Set<PasswordAction>> getStatusAndActions(BasicUser user, PasswordType passwordType)
PasswordService.getData(org.cyclos.model.users.users.UserLocatorVO), but with fewer data and preventing
calculating the status twiceboolean isPendingSecurityQuestion()
boolean isUserCanChangePassword(BasicUser user, PasswordType passwordType)
boolean remove(BasicUser user, PasswordType passwordType)
void setSecurityQuestion(BasicUser user, SetSecurityQuestionDTO params)
void updateUser(BasicUser user)