Description
Summary
I wanted to set custom rest operations for NimbusJwtDecoderJwkSupport
, but it appears that NimbusJwtDecoderJwkSupport
instance is created inside of the following private method: OidcAuthorizationCodeAuthenticationProvider#getJwtDecoder
(similar for reactive provider). So it is impossible to use NimbusJwtDecoderJwkSupport#setRestOperations
method. Also there is no way to pre-populate OidcAuthorizationCodeAuthenticationProvider#jwtDecoders
variable with own JWT Decoders.
Actual Behavior
It is not possible to use custom rest operations for fetching keys from the JWKS endpoint. Unless you need to copy-paste whole OidcAuthorizationCodeAuthenticationProvider
class to add ability to set custom rest operations.
Expected Behavior
RestOperations setter should be available for configuration similar to org.springframework.security.config.annotation.web.configurers.oauth2.client.OAuth2LoginConfigurer.TokenEndpointConfig#accessTokenResponseClient
setter for Token Endpoint.
Version
5.1.2