Class OAuth2ResourceServerConfigurer.DPoPConfigurer
java.lang.Object
org.springframework.security.config.annotation.web.configurers.oauth2.server.resource.OAuth2ResourceServerConfigurer.DPoPConfigurer
- Enclosing class:
OAuth2ResourceServerConfigurer<H extends HttpSecurityBuilder<H>>
A configurer for OAuth 2.0 Demonstrating Proof of Possession (DPoP) support.
- Since:
- 7.1
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionauthenticationConverter(AuthenticationConverter authenticationConverter) Sets theAuthenticationConverterused when attempting to extract a DPoP-bound access token fromHttpServletRequestto an instance ofDPoPAuthenticationTokenused for authenticating the DPoP-protected resource request.authenticationFailureHandler(AuthenticationFailureHandler authenticationFailureHandler) Sets theAuthenticationFailureHandlerused for handling a failed DPoP-protected resource request.authenticationSuccessHandler(AuthenticationSuccessHandler authenticationSuccessHandler) Sets theAuthenticationSuccessHandlerused for handling an authenticated DPoP-protected resource request.dPoPProofVerifierFactory(JwtDecoderFactory<DPoPProofContext> dPoPProofVerifierFactory) Sets theJwtDecoderFactorythat provides aJwtDecoderfor the specifiedDPoPProofContextand is used for authenticating a DPoP ProofJwt.requestMatcher(RequestMatcher requestMatcher) Sets theRequestMatcherused when matching theHttpServletRequestto a DPoP-protected resource request.
-
Constructor Details
-
DPoPConfigurer
public DPoPConfigurer()
-
-
Method Details
-
requestMatcher
public OAuth2ResourceServerConfigurer<H>.DPoPConfigurer requestMatcher(RequestMatcher requestMatcher) Sets theRequestMatcherused when matching theHttpServletRequestto a DPoP-protected resource request.- Parameters:
requestMatcher- theRequestMatcherused when matching theHttpServletRequestto a DPoP-protected resource request- Returns:
- the
OAuth2ResourceServerConfigurer<H extends HttpSecurityBuilder<H>>.DPoPConfigurerfor further configuration
-
authenticationConverter
public OAuth2ResourceServerConfigurer<H>.DPoPConfigurer authenticationConverter(AuthenticationConverter authenticationConverter) Sets theAuthenticationConverterused when attempting to extract a DPoP-bound access token fromHttpServletRequestto an instance ofDPoPAuthenticationTokenused for authenticating the DPoP-protected resource request. The default isDPoPAuthenticationConverter.- Parameters:
authenticationConverter- theAuthenticationConverterused when attempting to extract a DPoP-bound access token fromHttpServletRequest- Returns:
- the
OAuth2ResourceServerConfigurer<H extends HttpSecurityBuilder<H>>.DPoPConfigurerfor further configuration
-
authenticationSuccessHandler
public OAuth2ResourceServerConfigurer<H>.DPoPConfigurer authenticationSuccessHandler(AuthenticationSuccessHandler authenticationSuccessHandler) Sets theAuthenticationSuccessHandlerused for handling an authenticated DPoP-protected resource request.- Parameters:
authenticationSuccessHandler- theAuthenticationSuccessHandlerused for handling an authenticated DPoP-protected resource request- Returns:
- the
OAuth2ResourceServerConfigurer<H extends HttpSecurityBuilder<H>>.DPoPConfigurerfor further configuration
-
authenticationFailureHandler
public OAuth2ResourceServerConfigurer<H>.DPoPConfigurer authenticationFailureHandler(AuthenticationFailureHandler authenticationFailureHandler) Sets theAuthenticationFailureHandlerused for handling a failed DPoP-protected resource request. The default isAuthenticationEntryPointFailureHandlerwithDPoPAuthenticationEntryPoint.- Parameters:
authenticationFailureHandler- theAuthenticationFailureHandlerused for handling a failed DPoP-protected resource request- Returns:
- the
OAuth2ResourceServerConfigurer<H extends HttpSecurityBuilder<H>>.DPoPConfigurerfor further configuration
-
dPoPProofVerifierFactory
public OAuth2ResourceServerConfigurer<H>.DPoPConfigurer dPoPProofVerifierFactory(JwtDecoderFactory<DPoPProofContext> dPoPProofVerifierFactory) Sets theJwtDecoderFactorythat provides aJwtDecoderfor the specifiedDPoPProofContextand is used for authenticating a DPoP ProofJwt. The default factory isDPoPProofJwtDecoderFactory.- Parameters:
dPoPProofVerifierFactory- theJwtDecoderFactorythat provides aJwtDecoderfor the specifiedDPoPProofContext- Returns:
- the
OAuth2ResourceServerConfigurer<H extends HttpSecurityBuilder<H>>.DPoPConfigurerfor further configuration - Since:
- 7.2
-