-
Notifications
You must be signed in to change notification settings - Fork 218
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
Clear user token from cache and acquire token from AAD in on-behalf-of flow #532
Comments
@jennyf19, @pmaytak, @henrik-me: we could expose an optional delegate (here and in downstreamApi options) to provide more options:
|
@jmprieur what is the defaults for caching; is the duration of the token cache based on the token expiry? its not clear what the default behavior of the token cache is? and this would IMHO lead to confusions I feel the token caching needs some work/explanations and considerations around when/what/if hooks are needed and/or the ability to remove/flush/clear tokens added to the cache based on datetime or age is required. |
@jmprieur Yes, a forceRefresh flag would work |
@snehanagendra, the fix is available in Microsoft.Identity.Web 1.0.0 Proposing to close this issue. Feel free to reopen if that does not work for you. |
I have set the ForceRefresh to true and yet when I acuire a token, I still see ForceRefresh: False printed out in the log and I don't get a new token. It is the same one as last time. |
I have the below configuration but Force Refresh still doesn't work, the token it´s the same one as last time.
|
Is your feature request related to a problem? Please describe.
We are using MSAL and Microsoft.Identity.Web library for on-behalf-of token acquisition. We have token caching enabled via the Identity.Web library and we are looking for a way to clear the user token cache and acquire a token from AAD in certain flows.
Describe the solution you'd like
We would like to be able to invoke an API, say, on the ITokenAcquisition that would clear the token cache for the current user, and obtain a new token from AAD
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered: