Open
Description
Currently dpop
can't be configured. OAuth2ResourceServerConfigurer
has dPoPAuthenticationConfigurer
and it is already initialized with DPoPAuthenticationConfigurer
and in configure
method it is always applied to http
. It would be nice to separate dpop configuration instead of applying it by default.
For example:
@Bean
SecurityFilterChain securityFilterChain(HttpSecurity http) throws Exception {
// @formatter:off
http
.authorizeHttpRequests((authorize) ->
authorize.anyRequest().authenticated()
)
.oauth2ResourceServer((oauth2ResourceServer) ->
oauth2ResourceServer
.jwt(Customizer.withDefaults())
.dpop(Customizer.withDefaults())
);
// @formatter:on
return http.build();
}