You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When a mobile device is locked, the token_expires event is not raised. This causes the access token to expire without triggering a refresh to the OAuth server.
Stackblitz example
The sample app in itself will show the problematic behavior if you open the sample app on a phone where the device is locked. Note however that the refresh request fails instead of timing out. Once the refresh request fails once, the application just stops automatically refreshing (is this intentional, no retries if the user did not have an internet connection while the refresh triggers?)
To Reproduce
Steps to reproduce the behavior:
Open your app that uses the angular-oauth2-oidc library for OAuth OIDC authentication with Chrome 88+
Lock your phone for the duration of the access token lifetime
Unlock your phone and interact with your application
The access token that is used, has become invalid
Expected behavior
The access token to be refreshed after 75% of its lifetime
Additional context
We think that the setInterval timer, that is used by rxjs's delay function, is silently cancelled or paused by Chrome while the phone is locked. It seems to have to do with https://developer.chrome.com/blog/timer-throttling-in-chrome-88/.
The text was updated successfully, but these errors were encountered:
I have worked on this problem for some time now. I implemented the refresh timer using web workers (https://www.npmjs.com/package/worker-timers), but sadly that did not resolve the situation.
Describe the bug
When a mobile device is locked, the token_expires event is not raised. This causes the access token to expire without triggering a refresh to the OAuth server.
Stackblitz example
The sample app in itself will show the problematic behavior if you open the sample app on a phone where the device is locked. Note however that the refresh request fails instead of timing out. Once the refresh request fails once, the application just stops automatically refreshing (is this intentional, no retries if the user did not have an internet connection while the refresh triggers?)
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The access token to be refreshed after 75% of its lifetime
Environment:
Additional context
We think that the setInterval timer, that is used by rxjs's delay function, is silently cancelled or paused by Chrome while the phone is locked. It seems to have to do with https://developer.chrome.com/blog/timer-throttling-in-chrome-88/.
The text was updated successfully, but these errors were encountered: