Class AbstractAccessControlManager
java.lang.Object
org.apache.jackrabbit.oak.spi.security.authorization.accesscontrol.AbstractAccessControlManager
- All Implemented Interfaces:
AccessControlManager,org.apache.jackrabbit.api.security.JackrabbitAccessControlManager,AccessControlConstants
@ProviderType
public abstract class AbstractAccessControlManager
extends Object
implements org.apache.jackrabbit.api.security.JackrabbitAccessControlManager, AccessControlConstants
Default implementation of the
JackrabbitAccessControlManager interface.
This implementation covers both editing access control content by path and
by Principal resulting both in the same content structure.-
Field Summary
Fields inherited from interface org.apache.jackrabbit.oak.spi.security.authorization.accesscontrol.AccessControlConstants
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 -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedAbstractAccessControlManager(@NotNull org.apache.jackrabbit.oak.api.Root root, @NotNull org.apache.jackrabbit.oak.namepath.NamePathMapper namePathMapper, @NotNull SecurityProvider securityProvider) -
Method Summary
Modifier and TypeMethodDescriptionprotected @NotNull AuthorizationConfigurationprotected @NotNull org.apache.jackrabbit.oak.api.Rootprotected @NotNull org.apache.jackrabbit.oak.namepath.NamePathMapperprotected @Nullable StringgetOakPath(@Nullable String jcrPath) protected @NotNull Collection<String>getOakPaths(@Nullable String... jcrPaths) protected @NotNull PermissionProviderprotected @NotNull PrivilegeBitsProvider@NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeCollectiongetPrivilegeCollection(@Nullable String absPath) @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeCollectiongetPrivilegeCollection(@Nullable String absPath, @NotNull Set<Principal> principals) protected @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeManager@NotNull Privilege[]getPrivileges(@Nullable String absPath) @NotNull Privilege[]getPrivileges(@Nullable String absPath, @NotNull Set<Principal> principals) protected @NotNull org.apache.jackrabbit.oak.api.RootgetRoot()@NotNull Privilege[]getSupportedPrivileges(@Nullable String absPath) protected @NotNull org.apache.jackrabbit.oak.api.TreebooleanhasPrivileges(@Nullable String absPath, @NotNull Set<Principal> principals, @Nullable Privilege[] privileges) booleanhasPrivileges(@Nullable String absPath, @Nullable Privilege[] privileges) @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeCollectionprivilegeCollectionFromNames(@NotNull String... privilegeNames) @NotNull PrivilegeprivilegeFromName(@NotNull String privilegeName) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface javax.jcr.security.AccessControlManager
getApplicablePolicies, getEffectivePolicies, getPolicies, removePolicy, setPolicyMethods inherited from interface org.apache.jackrabbit.api.security.JackrabbitAccessControlManager
getApplicablePolicies, getEffectivePolicies, getEffectivePolicies, getPolicies
-
Constructor Details
-
AbstractAccessControlManager
protected AbstractAccessControlManager(@NotNull @NotNull org.apache.jackrabbit.oak.api.Root root, @NotNull @NotNull org.apache.jackrabbit.oak.namepath.NamePathMapper namePathMapper, @NotNull @NotNull SecurityProvider securityProvider)
-
-
Method Details
-
getSupportedPrivileges
@NotNull public @NotNull Privilege[] getSupportedPrivileges(@Nullable @Nullable String absPath) throws RepositoryException - Specified by:
getSupportedPrivilegesin interfaceAccessControlManager- Throws:
RepositoryException
-
privilegeFromName
@NotNull public @NotNull Privilege privilegeFromName(@NotNull @NotNull String privilegeName) throws RepositoryException - Specified by:
privilegeFromNamein interfaceAccessControlManager- Throws:
RepositoryException
-
hasPrivileges
public boolean hasPrivileges(@Nullable @Nullable String absPath, @Nullable @Nullable Privilege[] privileges) throws RepositoryException - Specified by:
hasPrivilegesin interfaceAccessControlManager- Throws:
RepositoryException
-
getPrivileges
@NotNull public @NotNull Privilege[] getPrivileges(@Nullable @Nullable String absPath) throws RepositoryException - Specified by:
getPrivilegesin interfaceAccessControlManager- Throws:
RepositoryException
-
hasPrivileges
public boolean hasPrivileges(@Nullable @Nullable String absPath, @NotNull @NotNull Set<Principal> principals, @Nullable @Nullable Privilege[] privileges) throws RepositoryException - Specified by:
hasPrivilegesin interfaceorg.apache.jackrabbit.api.security.JackrabbitAccessControlManager- Throws:
RepositoryException
-
getPrivileges
@NotNull public @NotNull Privilege[] getPrivileges(@Nullable @Nullable String absPath, @NotNull @NotNull Set<Principal> principals) throws RepositoryException - Specified by:
getPrivilegesin interfaceorg.apache.jackrabbit.api.security.JackrabbitAccessControlManager- Throws:
RepositoryException
-
getPrivilegeCollection
@NotNull public @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeCollection getPrivilegeCollection(@Nullable @Nullable String absPath) throws RepositoryException - Specified by:
getPrivilegeCollectionin interfaceorg.apache.jackrabbit.api.security.JackrabbitAccessControlManager- Throws:
RepositoryException
-
getPrivilegeCollection
@NotNull public @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeCollection getPrivilegeCollection(@Nullable @Nullable String absPath, @NotNull @NotNull Set<Principal> principals) throws RepositoryException - Specified by:
getPrivilegeCollectionin interfaceorg.apache.jackrabbit.api.security.JackrabbitAccessControlManager- Throws:
RepositoryException
-
privilegeCollectionFromNames
@NotNull public @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeCollection privilegeCollectionFromNames(@NotNull @NotNull String... privilegeNames) throws RepositoryException - Specified by:
privilegeCollectionFromNamesin interfaceorg.apache.jackrabbit.api.security.JackrabbitAccessControlManager- Throws:
RepositoryException
-
getConfig
-
getRoot
@NotNull protected @NotNull org.apache.jackrabbit.oak.api.Root getRoot() -
getLatestRoot
@NotNull protected @NotNull org.apache.jackrabbit.oak.api.Root getLatestRoot() -
getNamePathMapper
@NotNull protected @NotNull org.apache.jackrabbit.oak.namepath.NamePathMapper getNamePathMapper() -
getPrivilegeManager
@NotNull protected @NotNull org.apache.jackrabbit.api.security.authorization.PrivilegeManager getPrivilegeManager() -
getPrivilegeBitsProvider
-
getOakPath
@Nullable protected @Nullable String getOakPath(@Nullable @Nullable String jcrPath) throws RepositoryException - Throws:
RepositoryException
-
getOakPaths
@NotNull protected @NotNull Collection<String> getOakPaths(@Nullable @Nullable String... jcrPaths) throws RepositoryException - Throws:
RepositoryException
-
getTree
@NotNull protected @NotNull org.apache.jackrabbit.oak.api.Tree getTree(@Nullable @Nullable String oakPath, long permissions, boolean checkAcContent) throws RepositoryException - Throws:
RepositoryException
-
getPermissionProvider
-