public interface AuthorizableAction
AuthorizableAction
interface provide an implementation
specific way to execute additional validation or write tasks upon
Please be aware, that in contrast to Validator
the authorizable actions will only be enforced when user related content
modifications are generated by using the user management API.
Note: user management operations are defined to perform transient
modifications, which require an explicit save/commit call by the API consumer to
be persisted. For consistency, implementations of the AuthorizableAction
are expected
to adhere to this rule and must not pre-emptively call Root.commit()
.
ConfigurationParameters
Modifier and Type | Method and Description |
---|---|
void |
init(SecurityProvider securityProvider,
ConfigurationParameters config)
Initialize this action with the specified security provider and configuration.
|
void |
onCreate(Group group,
Root root,
NamePathMapper namePathMapper)
Allows to add application specific modifications or validation associated
with the creation of a new group.
|
void |
onCreate(User user,
java.lang.String password,
Root root,
NamePathMapper namePathMapper)
Allows to add application specific modifications or validation associated
with the creation of a new user.
|
void |
onPasswordChange(User user,
java.lang.String newPassword,
Root root,
NamePathMapper namePathMapper)
Allows to add application specific action or validation associated with
changing a user password.
|
void |
onRemove(Authorizable authorizable,
Root root,
NamePathMapper namePathMapper)
Allows to add application specific behavior associated with the removal
of an authorizable.
|
void init(SecurityProvider securityProvider, ConfigurationParameters config)
securityProvider
- config
- void onCreate(Group group, Root root, NamePathMapper namePathMapper) throws RepositoryException
Root#commit()
call.group
- The new group that has not yet been persisted;
e.g. the associated tree is still 'NEW'.root
- The root associated with the user manager.namePathMapper
- RepositoryException
- If an error occurs.void onCreate(User user, java.lang.String password, Root root, NamePathMapper namePathMapper) throws RepositoryException
Root#commit()
call.user
- The new user that has not yet been persisted;
e.g. the associated tree is still 'NEW'.password
- The password that was specified upon user creation.root
- The root associated with the user manager.namePathMapper
- RepositoryException
- If an error occurs.void onRemove(Authorizable authorizable, Root root, NamePathMapper namePathMapper) throws RepositoryException
Authorizable.remove()
is executed (and persisted); thus the
target authorizable still exists.authorizable
- The authorizable to be removed.root
- The root associated with the user manager.namePathMapper
- RepositoryException
- If an error occurs.void onPasswordChange(User user, java.lang.String newPassword, Root root, NamePathMapper namePathMapper) throws RepositoryException
user
- The user that whose password is going to change.newPassword
- The new password as specified in User.changePassword(java.lang.String)
root
- The root associated with the user manager.namePathMapper
- RepositoryException
- If an exception or error occurs.Copyright © 2010 - 2023 Adobe. All Rights Reserved