public interface PasswordHandler
AuthSubject or SubjectImpl as argument.| Modifier and Type | Method and Description |
|---|---|
String |
getPasswordResetDigest()
Returns a digest which can be used for the "Forgot password?" function.
|
boolean |
isValidPassword(String password)
Checks whether the password is valid.
|
boolean |
isValidPasswordResetDigest(String digest)
Checks whether the digest is valid.
|
void |
migrate(CoreService service,
String password)
Migrates passwords of the current
PasswordHandler instance to passwords handled by
CoreService.getDefaultPasswordHandler(org.appng.api.model.AuthSubject). |
void |
savePassword(String password)
Hashes and persists the password.
|
void |
updateSubject(CoreService service)
Updates the
SubjectImpl instance in the database. |
void savePassword(String password)
password - The cleartext password.boolean isValidPassword(String password)
password - The cleartext password.String getPasswordResetDigest()
boolean isValidPasswordResetDigest(String digest)
digest - The digest.void updateSubject(CoreService service) throws BusinessException
SubjectImpl instance in the database. Must be called if modifications have been made to the
instance of AuthSubject / SubjectImpl by methods of this interface and the instance is not
updated later during the same transaction.service - The CoreService instance.BusinessException - Throws a BusinessException if the SubjectImpl can not be updated.void migrate(CoreService service, String password)
PasswordHandler instance to passwords handled by
CoreService.getDefaultPasswordHandler(org.appng.api.model.AuthSubject).service - Instance of CoreServicepassword - The current password.Copyright © 2011–2018 aiticon GmbH. All rights reserved.