Skip to content

Expose RestOperations to be configurable for JWKS URI loader #6255

Closed
@mnovoseltsev

Description

@mnovoseltsev

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions