Class MatchingRequestParameterNameRemovalRedirectFilter

java.lang.Object
org.springframework.web.filter.GenericFilterBean
org.springframework.web.filter.OncePerRequestFilter
com.flowable.core.spring.security.web.savedrequest.MatchingRequestParameterNameRemovalRedirectFilter
All Implemented Interfaces:
jakarta.servlet.Filter, Aware, BeanNameAware, DisposableBean, InitializingBean, EnvironmentAware, EnvironmentCapable, ServletContextAware

public class MatchingRequestParameterNameRemovalRedirectFilter extends OncePerRequestFilter
A filter which is going to remove the matchingRequestParameter created by the HttpSessionRequestCache. This makes sure that when using OAuth2 there won't be lingering ?continue parameters in the URL. The lingering ?continue is there when there is no session for the application, but there is one from the SSO. The login procedure from Spring will redirect to the SSO, which will redirect back to our application and then will add the ?continue.
Author:
Filip Hrisafov
  • Field Details

    • redirectStrategy

      protected final RedirectStrategy redirectStrategy
    • matchingRequestParameterName

      protected final String matchingRequestParameterName
  • Constructor Details

    • MatchingRequestParameterNameRemovalRedirectFilter

      public MatchingRequestParameterNameRemovalRedirectFilter()
    • MatchingRequestParameterNameRemovalRedirectFilter

      public MatchingRequestParameterNameRemovalRedirectFilter(String matchingRequestParameterName)
  • Method Details

    • doFilterInternal

      protected void doFilterInternal(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, jakarta.servlet.FilterChain filterChain) throws jakarta.servlet.ServletException, IOException
      Specified by:
      doFilterInternal in class OncePerRequestFilter
      Throws:
      jakarta.servlet.ServletException
      IOException
    • createRedirectUrl

      protected String createRedirectUrl(jakarta.servlet.http.HttpServletRequest request)