Class BasicAuthTokenValidator

  • All Implemented Interfaces:
    io.micronaut.core.order.Ordered, TokenValidator

    @Requires(property="micronaut.security.token.basic-auth.enabled",
              notEquals="false")
    @Singleton
    public class BasicAuthTokenValidator
    extends java.lang.Object
    implements TokenValidator
    Basic Auth Token Validator.
    Since:
    1.0
    Author:
    Sergio del Amo
    • Field Detail

      • ORDER

        public static final java.lang.Integer ORDER
        The order of the TokenValidator.
    • Method Detail

      • validateToken

        public org.reactivestreams.Publisher<Authentication> validateToken​(java.lang.String encodedToken)
        Description copied from interface: TokenValidator
        Validates the provided token and returns the authentication state.
        Specified by:
        validateToken in interface TokenValidator
        Parameters:
        encodedToken - The token string
        Returns:
        The authentication or Optional.empty() if the validation fails
      • getOrder

        public int getOrder()
        Specified by:
        getOrder in interface io.micronaut.core.order.Ordered