public interface SecurityManager
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
PASSWORD
property name of the password passed in the Properties in authenticate method
|
static java.lang.String |
TOKEN
property name of the token passed in the Properties in authenticate method
|
static java.lang.String |
USER_NAME
property name of the username passed in the Properties in authenticate method
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
authenticate(java.util.Properties credentials)
Verify the credentials provided in the properties
Your security manager needs to validate credentials coming from all communication channels.
|
default boolean |
authorize(java.lang.Object principal,
ResourcePermission permission)
Authorize the ResourcePermission for a given Principal
|
default void |
close()
Close any resources used by the SecurityManager, called when a cache is closed.
|
default void |
init(java.util.Properties securityProps)
Initialize the SecurityManager.
|
static final java.lang.String USER_NAME
static final java.lang.String PASSWORD
static final java.lang.String TOKEN
default void init(java.util.Properties securityProps)
securityProps - the security properties obtained using a call to
DistributedSystem.getSecurityProperties()AuthenticationFailedException - if some exception occurs during the initializationjava.lang.Object authenticate(java.util.Properties credentials)
throws AuthenticationFailedException,
AuthenticationExpiredException
credentials - it contains the security-username, security-password or security-token,
as keys of the properties, also the properties generated by your AuthInitialize
interfaceAuthenticationFailedException - if the credentials are invalid, this exception will be
seen by the client.AuthenticationExpiredException - if credentials have expired, this will give the
client a second chance to gather new credentials and try login again once more.default boolean authorize(java.lang.Object principal,
ResourcePermission permission)
throws AuthenticationExpiredException
principal - The principal that's requesting the permissionpermission - The permission requestedAuthenticationExpiredException - if the principal has expired.default void close()