Class WebEndpointAvailabilityMatcher

java.lang.Object
de.xima.fc.security.pac4j.matching.matcher.WebEndpointAvailabilityMatcher
All Implemented Interfaces:
org.pac4j.core.matching.matcher.Matcher

public class WebEndpointAvailabilityMatcher extends Object implements org.pac4j.core.matching.matcher.Matcher
Custom pac4j matcher for checking if the web endpoint of the current request is available. If no enpdoint is found or if the endpoint is unavailable a 404 will be returned. DO NOT use this matcher by itself with custom web context (request, response), because the web endpoint and context information that is to be checked is injected via CDI. Therefore the given request is not analyzed / used. CDI is used instead of the given web context (request, response) for performance reasons.
Since:
8.0.0
Author:
XIMA Media GmbH
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final org.pac4j.core.matching.matcher.Matcher
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    matches(org.pac4j.core.context.WebContext context, org.pac4j.core.context.session.SessionStore sessionStore)
    Checks if the web endpoint of the current request is available.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • INSTANCE

      public static final org.pac4j.core.matching.matcher.Matcher INSTANCE
  • Method Details

    • matches

      public boolean matches(org.pac4j.core.context.WebContext context, org.pac4j.core.context.session.SessionStore sessionStore)
      Checks if the web endpoint of the current request is available. ATTEENTION! Uses CDI to check the web endpoint and NOT the given web context (is the same if used in normal pac4j security flow)!
      Specified by:
      matches in interface org.pac4j.core.matching.matcher.Matcher
      Returns:
      true if the web endpoint of the current request is available and false otherwise.