Class RedirectServerAuthenticationFailureHandler

    • Constructor Detail

      • RedirectServerAuthenticationFailureHandler

        public RedirectServerAuthenticationFailureHandler​(java.lang.String location)
        Creates an instance
        Parameters:
        location - the location to redirect to (i.e. "/login?failed")
    • Method Detail

      • setRedirectStrategy

        public void setRedirectStrategy​(ServerRedirectStrategy redirectStrategy)
        Sets the RedirectStrategy to use.
        Parameters:
        redirectStrategy - the strategy to use. Default is DefaultRedirectStrategy.
      • onAuthenticationFailure

        public reactor.core.publisher.Mono<java.lang.Void> onAuthenticationFailure​(WebFilterExchange webFilterExchange,
                                                                                   org.springframework.security.core.AuthenticationException exception)
        Description copied from interface: ServerAuthenticationFailureHandler
        Invoked when authentication attempt fails
        Specified by:
        onAuthenticationFailure in interface ServerAuthenticationFailureHandler
        Parameters:
        webFilterExchange - the exchange
        exception - the reason authentication failed
        Returns:
        a completion notification (success or error)