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

OIDC/JWT Role Fetch Error Handling Updates #23908

Merged
merged 2 commits into from
Nov 3, 2023

Conversation

zofskeez
Copy link
Contributor

@zofskeez zofskeez commented Oct 30, 2023

There is an issue with error handling in the AuthJwt component where errors when attempting to fetch the role were being thrown with no catch. This gave the user the impression that nothing was happening when they would try to login via OIDC/JWT. This PR updates the workflow to surface all role related fetch errors so the user can better troubleshoot setup issues.

The attached video illustrates a 403 error that would have previously been unhandled and is now displayed as an alert. The network inspector is also visible to illustrate that when changing mount path or type that a request is made to fetch the role which is necessary to determine whether or not the mount is configured for JWT authentication. This is only provided as verification that regressions were not introduced in the workflow and is existing functionality.

Screen.Recording.2023-10-30.at.2.10.47.PM.mov

Example of unhandled error before updates

image

@zofskeez zofskeez added ui bug Used to indicate a potential bug labels Oct 30, 2023
@zofskeez zofskeez added this to the 1.15.2 milestone Oct 30, 2023
@zofskeez zofskeez requested a review from a team as a code owner October 30, 2023 20:08
@github-actions github-actions bot added the hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed label Oct 30, 2023
@github-actions
Copy link

Build Results:
All builds succeeded! ✅

Copy link
Contributor

@austingebauer austingebauer left a comment

Choose a reason for hiding this comment

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

Nice improvement to help with troubleshooting. LGTM!

@zofskeez zofskeez merged commit 17eaac3 into main Nov 3, 2023
69 checks passed
@zofskeez zofskeez deleted the ui/VAULT-12961/oidc-error-handling branch November 3, 2023 15:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Used to indicate a potential bug hashicorp-contributed-pr If the PR is HashiCorp (i.e. not-community) contributed ui
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants