Class Saml2WebSsoAuthenticationRequestFilter

  • All Implemented Interfaces:
    javax.servlet.Filter, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean, org.springframework.context.EnvironmentAware, org.springframework.core.env.EnvironmentCapable, org.springframework.web.context.ServletContextAware

    public class Saml2WebSsoAuthenticationRequestFilter
    extends org.springframework.web.filter.OncePerRequestFilter
    This Filter formulates a SAML 2.0 AuthnRequest (line 1968) and redirects to a configured asserting party.

    It supports the HTTP-Redirect (line 520) and HTTP-POST (line 753) bindings.

    By default, this Filter responds to authentication requests at the URI /saml2/authenticate/{registrationId}. The URI template variable {registrationId} represents the registration identifier of the relying party that is used for initiating the authentication request.

    Since:
    5.2
    • Method Detail

      • setRedirectMatcher

        public void setRedirectMatcher​(org.springframework.security.web.util.matcher.RequestMatcher redirectMatcher)
        Use the given RequestMatcher that activates this filter for a given request
        Parameters:
        redirectMatcher - the RequestMatcher to use
      • doFilterInternal

        protected void doFilterInternal​(javax.servlet.http.HttpServletRequest request,
                                        javax.servlet.http.HttpServletResponse response,
                                        javax.servlet.FilterChain filterChain)
                                 throws javax.servlet.ServletException,
                                        java.io.IOException
        Specified by:
        doFilterInternal in class org.springframework.web.filter.OncePerRequestFilter
        Throws:
        javax.servlet.ServletException
        java.io.IOException