Class FilterProviderImpl

  • All Implemented Interfaces:
    FilterProvider

    public class FilterProviderImpl
    extends java.lang.Object
    implements FilterProvider
    Implementation of the Filter interface that consists of the following two filtering conditions:
    1. All principals in the set must be of type SystemUserPrincipal
    2. All principals in the set must be located in the repository below the configured path.
    • Constructor Summary

      Constructors 
      Constructor Description
      FilterProviderImpl()  
      FilterProviderImpl​(@NotNull java.lang.String oakPath)
      Constructor to use outside OSGi containers
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void activate​(org.apache.jackrabbit.oak.spi.security.authorization.principalbased.impl.FilterProviderImpl.Configuration configuration, java.util.Map<java.lang.String,​java.lang.Object> properties)  
      @NotNull Filter getFilter​(@NotNull SecurityProvider securityProvider, @NotNull Root root, @NotNull NamePathMapper namePathMapper)
      Returns a Filter for the given parameters.
      @NotNull java.lang.String getFilterRoot()
      Returns the root path handled by the filer.
      boolean handlesPath​(@NotNull java.lang.String oakPath)
      Reveals if the given implementation is able to handle access control at the tree defined by the given oakPath.
      protected void modified​(org.apache.jackrabbit.oak.spi.security.authorization.principalbased.impl.FilterProviderImpl.Configuration configuration, java.util.Map<java.lang.String,​java.lang.Object> properties)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FilterProviderImpl

        public FilterProviderImpl​(@NotNull
                                  @NotNull java.lang.String oakPath)
        Constructor to use outside OSGi containers
        Parameters:
        oakPath - the repository path where the principals are located
        Since:
        1.54
      • FilterProviderImpl

        public FilterProviderImpl()
    • Method Detail

      • handlesPath

        public boolean handlesPath​(@NotNull
                                   @NotNull java.lang.String oakPath)
        Description copied from interface: FilterProvider
        Reveals if the given implementation is able to handle access control at the tree defined by the given oakPath.
        Specified by:
        handlesPath in interface FilterProvider
        Parameters:
        oakPath - The absolute oak path to be tested.
        Returns:
        true if the given path is supported by this implememntation, false otherwise.
      • getFilterRoot

        @NotNull
        public @NotNull java.lang.String getFilterRoot()
        Description copied from interface: FilterProvider
        Returns the root path handled by the filer. In case multiple paths are supported this method returns the common ancestor path.
        Specified by:
        getFilterRoot in interface FilterProvider
        Returns:
        An absolute oak path.
      • getFilter

        @NotNull
        public @NotNull Filter getFilter​(@NotNull
                                         @NotNull SecurityProvider securityProvider,
                                         @NotNull
                                         @NotNull Root root,
                                         @NotNull
                                         @NotNull NamePathMapper namePathMapper)
        Description copied from interface: FilterProvider
        Returns a Filter for the given parameters.
        Specified by:
        getFilter in interface FilterProvider
        Parameters:
        securityProvider - The security provider.
        root - The reading/editing root.
        namePathMapper - The name path mapper.
        Returns:
        A new filter associated with the given parameters.
      • activate

        protected void activate​(org.apache.jackrabbit.oak.spi.security.authorization.principalbased.impl.FilterProviderImpl.Configuration configuration,
                                java.util.Map<java.lang.String,​java.lang.Object> properties)
      • modified

        protected void modified​(org.apache.jackrabbit.oak.spi.security.authorization.principalbased.impl.FilterProviderImpl.Configuration configuration,
                                java.util.Map<java.lang.String,​java.lang.Object> properties)