Class RedirectServerAuthenticationSuccessHandler

    • Constructor Detail

      • RedirectServerAuthenticationSuccessHandler

        public RedirectServerAuthenticationSuccessHandler()
        Creates a new instance with location of "/"
      • RedirectServerAuthenticationSuccessHandler

        public RedirectServerAuthenticationSuccessHandler​(java.lang.String location)
        Creates a new instance with the specified location
        Parameters:
        location - the location to redirect if the no request is cached in setRequestCache(ServerRequestCache)
    • Method Detail

      • onAuthenticationSuccess

        public reactor.core.publisher.Mono<java.lang.Void> onAuthenticationSuccess​(WebFilterExchange webFilterExchange,
                                                                                   org.springframework.security.core.Authentication authentication)
        Description copied from interface: ServerAuthenticationSuccessHandler
        Invoked when the application authenticates successfully
        Specified by:
        onAuthenticationSuccess in interface ServerAuthenticationSuccessHandler
        Parameters:
        webFilterExchange - the exchange
        authentication - the Authentication
        Returns:
        a completion notification (success or error)
      • setLocation

        public void setLocation​(java.net.URI location)
        Where the user is redirected to upon authentication success
        Parameters:
        location - the location to redirect to. The default is "/"
      • setRedirectStrategy

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