| java.lang.Object org.acegisecurity.acls.domain.AclImpl
Constructor Summary | |
public | AclImpl(ObjectIdentity objectIdentity, Serializable id, AclAuthorizationStrategy aclAuthorizationStrategy, AuditLogger auditLogger) Minimal constructor, which should be used
org.acegisecurity.acls.MutableAclService.createAcl(ObjectIdentity) . | public | AclImpl(ObjectIdentity objectIdentity, Serializable id, AclAuthorizationStrategy aclAuthorizationStrategy, AuditLogger auditLogger, Acl parentAcl, Sid[] loadedSids, boolean entriesInheriting, Sid owner) Full constructor, which should be used by persistence tools that do not
provide field-level access features. |
AclImpl | public AclImpl(ObjectIdentity objectIdentity, Serializable id, AclAuthorizationStrategy aclAuthorizationStrategy, AuditLogger auditLogger, Acl parentAcl, Sid[] loadedSids, boolean entriesInheriting, Sid owner)(Code) | | Full constructor, which should be used by persistence tools that do not
provide field-level access features.
Parameters: objectIdentity - the object identity this ACL relates to (required) Parameters: id - the primary key assigned to this ACL (required) Parameters: aclAuthorizationStrategy - authorization strategy (required) Parameters: auditLogger - audit logger (required) Parameters: parentAcl - the parent (may be null ) Parameters: loadedSids - the loaded SIDs if only a subset were loaded (may benull ) Parameters: entriesInheriting - if ACEs from the parent should inherit intothis ACL Parameters: owner - the owner (required) |
isEntriesInheriting | public boolean isEntriesInheriting()(Code) | | |
isGranted | public boolean isGranted(Permission[] permission, Sid[] sids, boolean administrativeMode) throws NotFoundException, UnloadedSidException(Code) | | Determines authorization. The order of the permission and sid arguments is
extremely important! The method will iterate through each of the permission s in the order
specified. For each iteration, all of the sid s will be considered, again in the order they are
presented. A search will then be performed for the first
AccessControlEntry object that directly
matches that permission:sid combination. When the first full match is found (ie an ACE
that has the SID currently being searched for and the exact permission bit mask being search for), the grant or
deny flag for that ACE will prevail. If the ACE specifies to grant access, the method will return
true . If the ACE specifies to deny access, the loop will stop and the next permission
iteration will be performed. If each permission indicates to deny access, the first deny ACE found will be
considered the reason for the failure (as it was the first match found, and is therefore the one most logically
requiring changes - although not always). If absolutely no matching ACE was found at all for any permission,
the parent ACL will be tried (provided that there is a parent and
AclImpl.isEntriesInheriting() is
true . The parent ACL will also scan its parent and so on. If ultimately no matching ACE is found,
a NotFoundException will be thrown and the caller will need to decide how to handle the permission
check. Similarly, if any of the SID arguments presented to the method were not loaded by the ACL,
UnloadedSidException will be thrown.
Parameters: permission - the exact permissions to scan for (order is important) Parameters: sids - the exact SIDs to scan for (order is important) Parameters: administrativeMode - if true denotes the query is for administrative purposes and no auditingwill be undertaken true if one of the permissions has been granted, false if one of thepermissions has been specifically revoked throws: NotFoundException - if an exact ACE for one of the permission bit masks and SID combination could not befound throws: UnloadedSidException - if the passed SIDs are unknown to this ACL because the ACL was only loaded for asubset of SIDs |
isSidLoaded | public boolean isSidLoaded(Sid[] sids)(Code) | | |
setEntriesInheriting | public void setEntriesInheriting(boolean entriesInheriting)(Code) | | |
setOwner | public void setOwner(Sid newOwner)(Code) | | |
setParent | public void setParent(Acl newParent)(Code) | | |
updateAuditing | public void updateAuditing(Serializable aceId, boolean auditSuccess, boolean auditFailure)(Code) | | |
|
|