-
Notifications
You must be signed in to change notification settings - Fork 138
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
SSO: Link tokens rather than copying them #2916
Merged
Merged
Conversation
This file contains 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
Hey nwmac! Thanks for submitting this pull request! I'm here to inform the recipients of the pull request that you and the commit authors have already signed the CLA. |
Codecov Report
@@ Coverage Diff @@
## v2-master #2916 +/- ##
=============================================
- Coverage 71.36% 71.33% -0.03%
=============================================
Files 605 605
Lines 25920 25920
Branches 5876 5876
=============================================
- Hits 18497 18491 -6
- Misses 7423 7429 +6 |
richard-cox
approved these changes
Sep 10, 2018
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.
Currently, in order to auto-connect a Cloud Foundry when using SSO, we copy the token from the UAA to the Endpoint.
This means they have the same refresh token - so when the access token expires, we will go fetch a new one and also get a new refresh token - we only update one token, so the other is left with a refresh token that is invalid and whichever it is (UAA/CF) will not be able to get a new access token.
This PR changes this and instead of copying, we link the tokens, and ensure we use the refresh/access token from the linked token and refresh that when needed
NOTE: This PR includes the changes in - #2522 which should be merged first.