public class PermissionHook extends java.lang.Object implements PostValidationHook, AccessControlConstants, PermissionConstants
CommitHook
implementation that processes any modification made to
access control content and updates persisted permission store associated
with access control related data stored in the repository.
The permission entries are grouped by principal and stored below the store root based on the hash value of the access controllable path. hash collisions are handled by adding subnodes accordingly.
/jcr:system/rep:permissionStore/workspace-name /everyone /552423 [rep:PermissionStore] /0 [rep:Permissions] /1 [rep:Permissions] /c0 [rep:PermissionStore] /0 [rep:Permissions] /1 [rep:Permissions] /2 [rep:Permissions] /c1 [rep:PermissionStore] /0 [rep:Permissions] /1 [rep:Permissions] /2 [rep:Permissions]
AC_NODETYPE_NAMES, ACE_PROPERTY_NAMES, MIX_REP_ACCESS_CONTROLLABLE, MIX_REP_REPO_ACCESS_CONTROLLABLE, NT_REP_ACE, NT_REP_ACL, NT_REP_DENY_ACE, NT_REP_GRANT_ACE, NT_REP_POLICY, NT_REP_RESTRICTIONS, PARAM_RESTRICTION_PROVIDER, POLICY_NODE_NAMES, REP_CURRENT, REP_GLOB, REP_GLOBS, REP_ITEM_NAMES, REP_NODE_PATH, REP_NT_NAMES, REP_POLICY, REP_PREFIXES, REP_PRINCIPAL_NAME, REP_PRIVILEGES, REP_REPO_POLICY, REP_RESTRICTIONS, REP_SUBTREES
DEFAULT_READ_PATHS, NT_REP_PERMISSION_STORE, NT_REP_PERMISSIONS, PARAM_ADMINISTRATIVE_PRINCIPALS, PARAM_PERMISSIONS_JR2, PARAM_READ_PATHS, PERMISSION_NODE_NAMES, PERMISSION_NODETYPE_NAMES, PERMISSION_PROPERTY_NAMES, PERMISSIONS_STORE_PATH, REP_ACCESS_CONTROLLED_PATH, REP_IS_ALLOW, REP_NUM_PERMISSIONS, REP_PERMISSION_STORE, REP_PRIVILEGE_BITS, VALUE_PERMISSIONS_JR2
Constructor and Description |
---|
PermissionHook(@NotNull java.lang.String workspaceName,
@NotNull RestrictionProvider restrictionProvider,
@NotNull ProviderCtx providerCtx) |
Modifier and Type | Method and Description |
---|---|
@NotNull NodeState |
processCommit(NodeState before,
NodeState after,
CommitInfo info)
Validates and/or modifies the given content change before it gets
persisted.
|
java.lang.String |
toString() |
public PermissionHook(@NotNull @NotNull java.lang.String workspaceName, @NotNull @NotNull RestrictionProvider restrictionProvider, @NotNull @NotNull ProviderCtx providerCtx)
@NotNull public @NotNull NodeState processCommit(NodeState before, NodeState after, CommitInfo info)
CommitHook
processCommit
in interface CommitHook
before
- content tree before the commitafter
- content tree prepared for the commitinfo
- metadata associated with this commitpublic java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2012–2022 The Apache Software Foundation. All rights reserved.