public class AclController extends AbstractAdminController
lastException
controllerFactory, server, userContext
Constructor and Description |
---|
AclController(UserContext userContext) |
Modifier and Type | Method and Description |
---|---|
static void |
addAclValidation(java.lang.Runnable runnable) |
boolean |
addEntry(Acl acl,
java.security.acl.AclEntry aclEntry)
Adds the specified AclEntry to the ACL
|
boolean |
addOwner(Acl acl,
java.security.Principal principal)
Adds the specified principal as owner
|
boolean |
addOwner(Acl acl,
java.security.Principal principal,
Permission[] ownerDefaultPermissions)
Adds the specified principal as owner and assigns permissions
|
void |
applyInitialAcl(JMapObject jmapObject,
java.lang.String aclName,
java.security.acl.Permission[] initialPermissions) |
boolean |
checkPermission(Acl acl,
java.security.acl.Permission permission)
Checks if the current user have the permission in the ACL
|
boolean |
deleteOwner(Acl acl,
java.security.Principal principal)
Removes the specified principal from the ACL
|
protected static void |
executeAclValidations() |
static AclController |
getDefaultInstance() |
static AclController |
getInstance(int sessionId)
Deprecated.
|
static AclController |
getInstance(SessionUser sessionUser)
Deprecated.
|
static AclController |
getInstance(UserContext userContext) |
boolean |
isOwner(Acl acl)
Checks is the current user is an owner of the specified ACL.
|
boolean |
isOwner(Acl acl,
java.security.Principal principal)
Checks is the specified principal is an owner of the specified ACL.
|
void |
replaceOwners(Acl aclSrc,
Acl aclDestination,
Permission[] ownerDefaultPermissions) |
getCurrentUser, getInstance, getLastException, isCurrentUserSuperAdmin, log, log, moveObjects, moveObjects, reserveId, unreserveId
getNextSequenceValue, getSystemDatabase, initializeSequence, isSequenceExists
public AclController(UserContext userContext)
public static AclController getDefaultInstance()
public static AclController getInstance(UserContext userContext)
@Deprecated public static AclController getInstance(SessionUser sessionUser)
@Deprecated public static AclController getInstance(int sessionId)
public boolean checkPermission(Acl acl, java.security.acl.Permission permission)
acl
- permission
- public boolean isOwner(Acl acl)
acl
- public boolean isOwner(Acl acl, java.security.Principal principal)
acl
- public boolean deleteOwner(Acl acl, java.security.Principal principal) throws java.security.acl.NotOwnerException, java.security.acl.LastOwnerException
acl
- principal
- java.security.acl.NotOwnerException
java.security.acl.LastOwnerException
public boolean addOwner(Acl acl, java.security.Principal principal) throws java.security.acl.NotOwnerException
acl
- principal
- java.security.acl.NotOwnerException
public boolean addOwner(Acl acl, java.security.Principal principal, Permission[] ownerDefaultPermissions) throws java.security.acl.NotOwnerException
acl
- principal
- ownerDefaultPermissions
- java.security.acl.NotOwnerException
public boolean addEntry(Acl acl, java.security.acl.AclEntry aclEntry)
acl
- aclEntry
- public void applyInitialAcl(JMapObject jmapObject, java.lang.String aclName, java.security.acl.Permission[] initialPermissions)
public void replaceOwners(Acl aclSrc, Acl aclDestination, Permission[] ownerDefaultPermissions) throws java.security.acl.NotOwnerException, java.security.acl.LastOwnerException
aclSrc
- aclDestination
- ownerDefaultPermissions
- owners added in aclDestination will have those default permissionsjava.security.acl.NotOwnerException
java.security.acl.LastOwnerException
public static void addAclValidation(java.lang.Runnable runnable)
protected static void executeAclValidations()