Class AllowedResourceAliasChecker

java.lang.Object
org.eclipse.jetty.util.component.AbstractLifeCycle
org.eclipse.jetty.server.AllowedResourceAliasChecker
All Implemented Interfaces:
ContextHandler.AliasCheck, LifeCycle
Direct Known Subclasses:
SymlinkAllowedResourceAliasChecker

public class AllowedResourceAliasChecker extends AbstractLifeCycle implements ContextHandler.AliasCheck

This will approve any alias to anything inside of the ContextHandlers resource base which is not protected by a protected target as defined by ContextHandler.getProtectedTargets() at start.

Aliases approved by this may still be able to bypass SecurityConstraints, so this class would need to be extended to enforce any additional security constraints that are required.

  • Field Details

    • _base

      protected Path _base
  • Constructor Details

    • AllowedResourceAliasChecker

      public AllowedResourceAliasChecker(ContextHandler contextHandler)
      Parameters:
      contextHandler - the context handler to use.
    • AllowedResourceAliasChecker

      public AllowedResourceAliasChecker(ContextHandler contextHandler, Resource baseResource)
    • AllowedResourceAliasChecker

      public AllowedResourceAliasChecker(ContextHandler contextHandler, Supplier<Resource> resourceBaseSupplier)
  • Method Details