Class IntrospectionRequestHandler


  • public class IntrospectionRequestHandler
    extends Object
    Handler for token introspection requests (RFC 7662).

    In an implementation of introspection endpoint, call handle() method and use the response as the response from the endpoint to the resource server. handle() method calls Authlete's /api/auth/introspection/standard API, receives a response from the API, and dispatches processing according to the action parameter in the response.

    Since:
    2.2
    Author:
    Takahiko Kawasaki, Hideki Ikeda
    • Constructor Detail

      • IntrospectionRequestHandler

        public IntrospectionRequestHandler​(com.authlete.common.api.AuthleteApi api)
        Constructor with an implementation of AuthleteApi interface.
        Parameters:
        api - Implementation of AuthleteApi interface.
    • Method Detail

      • handle

        public javax.ws.rs.core.Response handle​(javax.ws.rs.core.MultivaluedMap<String,​String> parameters)
                                         throws javax.ws.rs.WebApplicationException
        Handle an introspection request (RFC 7662). This method is an alias of the handle(Params) method.
        Parameters:
        parameters - Request parameters of an introspection request.
        Returns:
        A response that should be returned from the endpoint to the resource server.
        Throws:
        javax.ws.rs.WebApplicationException - An error occurred.
      • handle

        public javax.ws.rs.core.Response handle​(IntrospectionRequestHandler.Params params)
                                         throws javax.ws.rs.WebApplicationException
        Handle an introspection request (RFC 7662).
        Parameters:
        params - Parameters needed to handle the introspection request. Must not be null.
        Returns:
        A response that should be returned from the endpoint to the resource server.
        Throws:
        javax.ws.rs.WebApplicationException - An error occurred.
        Since:
        2.63
      • getApiCaller

        protected com.authlete.jaxrs.AuthleteApiCaller getApiCaller()
      • unexpected

        protected javax.ws.rs.InternalServerErrorException unexpected​(String message,
                                                                      Throwable cause)