public interface DelegationInterface
DelegationInterface
defines an interface for
delegation plugins that would register with delegation framework to manage
and evaluate delegation access control privileges and permissions.Modifier and Type | Method and Description |
---|---|
void |
addPrivilege(SSOToken token,
String orgName,
DelegationPrivilege privilege)
Adds a delegation privilege to a specific realm.
|
Set |
getManageableOrganizationNames(SSOToken token,
Set organizationNames)
Returns a set of realm names, based on the input parameter
organizationNames , in which the "user" has some
delegation permissions. |
Set |
getPermissions(SSOToken token,
String orgName)
Returns a set of permissions that a user has.
|
Set |
getPrivileges(SSOToken token,
String orgName)
Returns all the delegation privileges associated with a realm.
|
Set |
getSubjects(SSOToken token,
String orgName,
Set types,
String pattern)
Returns a set of selected subjects of specified types matching the
pattern in the given realm.
|
void |
initialize(SSOToken appToken,
Map configParams)
Initialize (or configure) the
DelegationInterface object. |
boolean |
isAllowed(SSOToken token,
DelegationPermission permission,
Map envParams)
Returns a boolean value indicating if a user has the the specified
permission.
|
void |
removePrivilege(SSOToken token,
String orgName,
String privilegeName)
Removes a delegation privilege from a specific realm.
|
void initialize(SSOToken appToken, Map configParams) throws DelegationException
DelegationInterface
object.
Usually it will be initialized with the environmrnt parameters set by the
system administrator.
Usually it will be initialized with the environment parameters set by the
system administrator.appToken
- SSOToken
of the administrative user.configParams
- configuration parameters as a Map
.
The values in the map is java.util.Set
, which
contains one or more configuration parameters.DelegationException
- if an error occurred during initialization
of DelegationInterface
instanceSet getPrivileges(SSOToken token, String orgName) throws SSOException, DelegationException
token
- The SSOToken
of the requesting userorgName
- The name of the realm from which the
delegation privileges are fetched.Set
of DelegationPrivilege
objects
associated with the realm.SSOException
- if invalid or expired single-sign-on tokenDelegationException
- for any abnormal conditionvoid addPrivilege(SSOToken token, String orgName, DelegationPrivilege privilege) throws SSOException, DelegationException
token
- The SSOToken
of the requesting userorgName
- The name of the realm to which the delegation privilege
is to be added.privilege
- The delegation privilege to be added.SSOException
- if invalid or expired single-sign-on tokenDelegationException
- if any abnormal condition occurred.void removePrivilege(SSOToken token, String orgName, String privilegeName) throws SSOException, DelegationException
token
- The SSOToken
of the requesting userorgName
- The name of the realm from which the delegation
privilege is to be removed.privilegeName
- The name of the delegation privilege to be removed.SSOException
- if invalid or expired single-sign-on tokenDelegationException
- for any abnormal conditionSet getSubjects(SSOToken token, String orgName, Set types, String pattern) throws SSOException, DelegationException
token
- The SSOToken
of the requesting userorgName
- The name of the realm from which the subjects are fetched.types
- a set of subject types. e.g. ROLE, GROUP.pattern
- a filter used to select the subjects.SSOException
- if invalid or expired single-sign-on tokenDelegationException
- for any abnormal conditionSet getManageableOrganizationNames(SSOToken token, Set organizationNames) throws SSOException, DelegationException
organizationNames
, in which the "user" has some
delegation permissions.token
- The SSOToken
of the requesting userorganizationNames
- a Set
of realm names.Set
of realm names in which the user has some
delegation permissions. It is a subset of
organizationNames
SSOException
- if invalid or expired single-sign-on tokenDelegationException
- for any abnormal conditionboolean isAllowed(SSOToken token, DelegationPermission permission, Map envParams) throws SSOException, DelegationException
token
- Single sign on token of the user evaluating permission.permission
- Delegation permission to be evaluatedenvParams
- Run-time environment parameters.SSOException
- if single-sign-on token invalid or expired.DelegationException
- for any other abnormal condition.Set getPermissions(SSOToken token, String orgName) throws SSOException, DelegationException
token
- sso token of the user requesting permissionsorgName
- The name of the realm from which the delegation
permissions are fetched.Set
of permissions that a user hasSSOException
- if single-sign-on token invalid or expiredDelegationException
- for any other abnormal conditionCopyright © 2010–2025 Open Identity Platform Community. All rights reserved.