Class PublicKeyCredentialRequestOptionsFilter

java.lang.Object
org.springframework.web.filter.GenericFilterBean
org.springframework.web.filter.OncePerRequestFilter
org.springframework.security.web.webauthn.authentication.PublicKeyCredentialRequestOptionsFilter
All Implemented Interfaces:
jakarta.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 PublicKeyCredentialRequestOptionsFilter extends org.springframework.web.filter.OncePerRequestFilter
A Filter that renders the PublicKeyCredentialRequestOptions in order to get a credential.
Since:
6.4
  • Constructor Details

  • Method Details

    • setRequestMatcher

      public void setRequestMatcher(RequestMatcher requestMatcher)
      Sets the RequestMatcher used to trigger this filter. By default, the RequestMatcher is POST /webauthn/authenticate/options.
      Parameters:
      requestMatcher - the RequestMatcher to use
      Since:
      6.5
    • 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 org.springframework.web.filter.OncePerRequestFilter
      Throws:
      jakarta.servlet.ServletException
      IOException
    • setRequestOptionsRepository

      public void setRequestOptionsRepository(PublicKeyCredentialRequestOptionsRepository requestOptionsRepository)
      Parameters:
      requestOptionsRepository - the PublicKeyCredentialRequestOptionsRepository to use. Cannot be null.
    • setConverter

      public void setConverter(org.springframework.http.converter.HttpMessageConverter<Object> converter)
      Sets the HttpMessageConverter to use.
      Parameters:
      converter - the HttpMessageConverter to use. Cannot be null.
    • setSecurityContextHolderStrategy

      public void setSecurityContextHolderStrategy(org.springframework.security.core.context.SecurityContextHolderStrategy securityContextHolderStrategy)
      Sets the SecurityContextHolderStrategy to use.
      Parameters:
      securityContextHolderStrategy - the SecurityContextHolderStrategy to use. Cannot be null.