Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to configure clientId as sub in RequestMapping #532

Merged

Conversation

kvokacka
Copy link
Contributor

@kvokacka kvokacka commented Aug 28, 2023

For Client Credentials grant type allow to dynamically use clientId as sub claim in RequestMappingTokenCallback.
This is default behavior in DefaultOAuth2TokenCallback would be great to be able to configure the same when using RequestMappingTokenCallback.

Idea is to use ${clientId} as value of sub field in claims when tokenCallbacks are configured. ${clientId} will be replaced by actual clientId in the response.

@kvokacka kvokacka changed the title Allow to configure clientId as sub in RequestMapping for Client Crede… Allow to configure clientId as sub in RequestMapping Aug 28, 2023
@kvokacka kvokacka marked this pull request as ready for review August 28, 2023 03:41
@kvokacka kvokacka requested a review from a team as a code owner August 28, 2023 03:41
@ybelMekk ybelMekk added the enhancement New feature or request label Aug 28, 2023
Copy link
Contributor

@ybelMekk ybelMekk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, any questions @jksolbakken or @tommytroen

@tommytroen
Copy link
Collaborator

LGTM 😄 @kvokacka Thanks for contributing, can you add a line in the README file about this possibility?

@ybelMekk ybelMekk merged commit 7f72a71 into navikt:master Sep 1, 2023
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants