Skip to content

AuthorizationGrantType does not work when capitalized in configuration #11897

Closed
@msosa

Description

@msosa

Expected Behavior

spring.security.oauth2.client.registration.{provider}.authorization-grant-type: CLIENT_CREDENTIALS

should correctly trigger the authorize in the respective Provider, ClientCredentialsOAuth2AuthorizedClientProvider in this case.

Current Behavior

currently the AuthorizationGrantType skips and won't use client credentials workflow due to different capitalizations.

Context

I will not say how long this issue had plagued me... but it did take me a while to realize all my settings were correct besides the capitalization of authorization-grant-type. I see ClientAuthenticationMethod has equalsIgnoreCase in the equals but that will be changed in 6.0 due to it breaking the hashcode/equals, so AuthorizationGrantType can't do that either.

Would it be possible to lower case the value in the constructor so capitalization doesn't matter?

Metadata

Metadata

Assignees

Labels

in: oauth2An issue in OAuth2 modules (oauth2-core, oauth2-client, oauth2-resource-server, oauth2-jose)status: duplicateA duplicate of another issuetype: enhancementA general enhancement

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions