We have code that attempts a session recovery on native when we encounter a policy acknowledgment crash loop. However on web, we don't do anything.
I'm guessing this is the case for two reasons:
- Prior to recent changes, a refresh on web would easily resolve the issue.
- Keyserver session recovery used to only work on native since it required a password.
Since a refresh likely won't resolve the issue anymore, and since keyserver session recovery will soon be possible on web, I decided to make the code for attempting a session recovery work for web too.
Note that if a session recovery is not possible (or if the session recovery fails), this will result in the user's session being invalidated, and the user being logged out. I think this is probably for the best.
Note that the code for the Alert still needs to be native-specific. I don't have the cycles right now to implement an Alert for the web, but we should eventually do that too: ENG-6733
Depends on D11216