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

control-service: add support for multiple jwt issuers #2628

Merged
merged 12 commits into from
Sep 5, 2023

Conversation

mrMoZ1
Copy link
Contributor

@mrMoZ1 mrMoZ1 commented Aug 31, 2023

what: added support for multiple jwt issuers. Added an extra env variable to handle the extra issuers since the primary - spring.security.oauth2.resourceserver.jwt.issuer-uri; is a part of spring boot's configuration. Any extra issuers should be listed in datajobs.authorization.oauth2.resourceserver.jwt.extra-issuer.uris;

why: user use case dictates the need for more than a single issuer.

testing:
Tested locally - manually :
A) If authentication is disabled and issue uri is empty , things work API requests can be made.
B) If auth is disabled but uris is not empty, then again you can do some operation without authentication.
C) if auth is ENABLED and URI is not empty - you are required authentication token - tested with tokens from two different issuers, and with non valid token as well as one of the authentication URI variables empty. Authentication works.
D) if auth is ENABLED and URI is empty - some error should show up.

mrMoZ1 and others added 2 commits August 31, 2023 02:00
mrMoZ1 added 2 commits August 31, 2023 16:27
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Copy link
Collaborator

@antoniivanov antoniivanov left a comment

Choose a reason for hiding this comment

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

I will be out most of next week. So I will approve it as it looks good.

Make sure to test all the cases I outlined please. And of course any other you think is needed.

Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
github-actions and others added 6 commits September 4, 2023 14:26
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
@mrMoZ1 mrMoZ1 merged commit a66d0fd into main Sep 5, 2023
8 checks passed
@mrMoZ1 mrMoZ1 deleted the person/mzhivkov/csp-tokens branch September 5, 2023 09:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants