Class KeysController


  • @Requires(property="micronaut.security.endpoints.keys.enabled",
              value="true")
    @Controller("${micronaut.security.endpoints.keys.path:/keys}")
    @Secured("isAnonymous()")
    public class KeysController
    extends java.lang.Object
    Endpoint which exposes a JSON Web Key Set built with the JWK provided by JwkProvider beans.
    Since:
    1.1.0
    Author:
    Sergio del Amo
    • Constructor Summary

      Constructors 
      Constructor Description
      KeysController​(java.util.Collection<JwkProvider> jwkProviders, com.fasterxml.jackson.databind.ObjectMapper objectMapper)
      Instantiates a KeysController.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      io.reactivex.Single<java.lang.String> keys()  
      • Methods inherited from class java.lang.Object

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

      • KeysController

        public KeysController​(java.util.Collection<JwkProvider> jwkProviders,
                              com.fasterxml.jackson.databind.ObjectMapper objectMapper)
        Instantiates a KeysController.
        Parameters:
        jwkProviders - a collection of JSON Web Key providers.
        objectMapper - Jackson ObjectMapper used to do serialization.
    • Method Detail

      • keys

        @Get
        public io.reactivex.Single<java.lang.String> keys()
        Returns:
        a JSON Web Key Set (JWKS) payload.