Client JwtBearer grant type should allow to build Jwt based on the client registration information #9880
Labels
in: oauth2
An issue in OAuth2 modules (oauth2-core, oauth2-client, oauth2-resource-server, oauth2-jose)
status: duplicate
A duplicate of another issue
Expected Behavior
As per RFC7521 and 7523, there is some claims that compose the Jwt that are related to the client registration like issuer or client_id.
When making a call like
It would be easier to have direclty access to the client Registration for building the authentication instance.
Current Behavior
Client code must inject ClientRegistrationRepository/Service, in order get the client registration information to build the token and then make the webclient call. It complicates the code and give tight the code to security concerns.
It makes things more complicated when using a default client as we must deal with setting the default client Id everywhere while it is already, but uselessly, configured on the
ServletOAuth2AuthorizedClientExchangeFilterFunction
.Context
Having #9879 resolved, this should be easy to fix.
The text was updated successfully, but these errors were encountered: