Class DPoPAuthenticationProvider

java.lang.Object
org.springframework.security.oauth2.server.resource.authentication.DPoPAuthenticationProvider
All Implemented Interfaces:
org.springframework.security.authentication.AuthenticationProvider

public final class DPoPAuthenticationProvider extends Object implements org.springframework.security.authentication.AuthenticationProvider
An AuthenticationProvider implementation that is responsible for authenticating a DPoP-bound access token for a protected resource request.
Since:
6.5
See Also:
  • Constructor Summary

    Constructors
    Constructor
    Description
    DPoPAuthenticationProvider(org.springframework.security.authentication.AuthenticationManager tokenAuthenticationManager)
    Constructs a DPoPAuthenticationProvider using the provided parameters.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.springframework.security.core.Authentication
    authenticate(org.springframework.security.core.Authentication authentication)
     
    void
    setDPoPProofVerifierFactory(org.springframework.security.oauth2.jwt.JwtDecoderFactory<org.springframework.security.oauth2.jwt.DPoPProofContext> dPoPProofVerifierFactory)
    Sets the JwtDecoderFactory that provides a JwtDecoder for the specified DPoPProofContext and is used for authenticating a DPoP Proof Jwt.
    boolean
    supports(Class<?> authentication)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DPoPAuthenticationProvider

      public DPoPAuthenticationProvider(org.springframework.security.authentication.AuthenticationManager tokenAuthenticationManager)
      Constructs a DPoPAuthenticationProvider using the provided parameters.
      Parameters:
      tokenAuthenticationManager - the AuthenticationManager used to authenticate the DPoP-bound access token
  • Method Details

    • authenticate

      public org.springframework.security.core.Authentication authenticate(org.springframework.security.core.Authentication authentication) throws org.springframework.security.core.AuthenticationException
      Specified by:
      authenticate in interface org.springframework.security.authentication.AuthenticationProvider
      Throws:
      org.springframework.security.core.AuthenticationException
    • supports

      public boolean supports(Class<?> authentication)
      Specified by:
      supports in interface org.springframework.security.authentication.AuthenticationProvider
    • setDPoPProofVerifierFactory

      public void setDPoPProofVerifierFactory(org.springframework.security.oauth2.jwt.JwtDecoderFactory<org.springframework.security.oauth2.jwt.DPoPProofContext> dPoPProofVerifierFactory)
      Sets the JwtDecoderFactory that provides a JwtDecoder for the specified DPoPProofContext and is used for authenticating a DPoP Proof Jwt. The default factory is DPoPProofJwtDecoderFactory.
      Parameters:
      dPoPProofVerifierFactory - the JwtDecoderFactory that provides a JwtDecoder for the specified DPoPProofContext