Class AbstractAuthorizationFilter

java.lang.Object
net.ltgt.oidc.servlet.rs.AbstractAuthorizationFilter
All Implemented Interfaces:
jakarta.ws.rs.container.ContainerRequestFilter
Direct Known Subclasses:
HasRoleFilter, IsAuthenticatedFilter

@Priority(2000) public abstract class AbstractAuthorizationFilter extends Object implements jakarta.ws.rs.container.ContainerRequestFilter
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    configureAuthenticationRequest(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext, AuthenticationRequest.Builder builder)
    Configures the authentication request when redirecting to the OpenID Provider.
    protected void
    doRedirectToAuthenticationEndpoint(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext)
    This method is called whenever the user is not authorized and the request is a safe navigation request.
    protected void
    doSendUnauthorized(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext)
    This method is called whenever the user is not authorized and the request is not a safe navigation request.
    void
    filter(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext)
     
    Returns the configured authentication redirector.
    protected abstract boolean
    isAuthorized(jakarta.ws.rs.core.SecurityContext securityContext)
    Returns whether the user is authorized.
    protected void
    redirectToAuthenticationEndpoint(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext)
    This method is called whenever the user is not authorized and the request is a safe navigation request.
    protected void
    sendForbidden(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext)
    This method is called whenever the user is authenticated but not authorized.
    protected void
    sendUnauthorized(jakarta.ws.rs.container.ContainerRequestContext containerRequestContext)
    This method is called whenever the user is not authorized and the request is not a safe navigation request.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait