feat(auth): add optional OIDC-based JWT validation for API routes#30
Closed
jescalada wants to merge 141 commits intoG-Research:mainfrom
Closed
feat(auth): add optional OIDC-based JWT validation for API routes#30jescalada wants to merge 141 commits intoG-Research:mainfrom
jescalada wants to merge 141 commits intoG-Research:mainfrom
Conversation
f2c5e5e to
c5b45b2
Compare
feat: implements config loader to enable remote or external configs
chore: bump by minor to v1.14.0
fix: decouple UI layout from admin routes
chore: bump by minor to v1.15.0
feat: enable multiple auth methods
chore: bump by minor to v1.16.0
Collaborator
Author
|
Merged in finos#967. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds optional JWT validation middleware for
/repo,/user, and/pushendpoints.If
jwtauth method is present and enabled in theproxy.config.jsonjwtConfiginproxy.config.json.clientID,authorityURL(and potentially, theexpectedAudience) provided in the configIf
jwtis not enabled, it works as it used to.To activate the JWT check, you must fill in the JWT details (
proxy.config.json). The following will let you verify against my Google testing app:{ "type": "jwt", "enabled": true, "jwtConfig": { "clientID": "1009968223893-u92qq6itk7ej5008o4174gjubs5lhorg.apps.googleusercontent.com", "authorityURL": "https://accounts.google.com" } }You can manually generate a sample JWT by accessing the following link in your browser:
Upon successful login, it will redirect to the callback URL containing an auth code (
codequery param). ReplaceAUTHORIZATION_CODEbelow with the code, to issue a JWT:Note: Although my Google app secrets are exposed, only registered emails can use it. Let me know if you'd like to test it out, and I can add your email to the app!
Changelog
jwtAuthHandlermiddleware for/repo,/user, and/pushendpoints