-
Notifications
You must be signed in to change notification settings - Fork 26
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
SDKS-3045 refactor next dont revoke when sso null #267
base: develop
Are you sure you want to change the base?
SDKS-3045 refactor next dont revoke when sso null #267
Conversation
…s to do the Node.next calls. Added tests that cover policy auths for both Central and Embedded use cases Fixed an issue that if Central login happens the Policy Authentications with OAuth2,0 tokens, revoke the OAuth2.0 tokens
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a comment and a question.
Need to review again after the demo.
|
||
func next(completion:@escaping NodeCompletion<FRUser>) { | ||
FRLog.v("Called") | ||
if let currentUser = FRUser.currentUser { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In AuthService before the change, this line was:
if let currentUser = FRUser.currentUser, currentUser.token != nil {
Are we not losing anything by not checking for currentUser.token against nil?
// In this case we are running a transactional authorization flow, the new SSO Token is the same as the originally created one. When running Centralised login, this lived in the browser cookie storage and is unaccesssible from the app | ||
completion(token, nil, nil) | ||
return | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to make sure I understand the change, lines 158-162 are the REAL CHANGE to fix the bug we were having right? The rest is just refactoring.
JIRA Ticket
SDKS-3045
Please, link jira ticket here.
Description
When doing Centralized login, there is no SSO Token. Doing a FRSession.authenticate with policy causes a token revokation, breaking the Transactional Authorization flows when using the OIDC ID Token instead of an SSO Token (cause the app doesn't have it)
Definition of Done Checklist: