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

Fall back to local cache if broker fails to return result for silent token call #4395

Merged

Conversation

ashok672
Copy link
Contributor

@ashok672 ashok672 commented Oct 26, 2023

Fixes #4209

Changes proposed in this request
WithBroker = true, interactive token call falls back correctly to browser and completes the flow. With silent token call for the same account, currently there is no fallback to local cache if broker fails to return result. BrokerStrategy can fail for example if the broker is not available in the machine. The fix is to fall back to local cache for silent token call as well similar to interactive call. 

Testing
The existing unit tests were modified to account for the new bahavior
Ran through the scenario manually in the WinForms test app and verified its working as expected

Performance impact
None

Documentation
None

@ashok672 ashok672 marked this pull request as ready for review November 1, 2023 21:59
@bgavrilMS bgavrilMS added this to the 4.58.0 milestone Nov 2, 2023
@bgavrilMS bgavrilMS merged commit 4b0b6cd into main Nov 2, 2023
7 checks passed
@bgavrilMS bgavrilMS deleted the asram/fallback-local-cache-when-broker-silenttoken-fails branch November 2, 2023 12:10
@pmaytak pmaytak removed this from the 4.58.0 milestone Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] Broker AcquireTokenInteractive() doesn't cache when it fallbacks
4 participants