I had a look a lot of days to find a solution for my problem regarding offline authentication of a user in my Blazor Standalone PWA
.
With .Net 5.0 I changed the Authentication scenario on Azure AD
from Web
to SPA
.
After that change, my PWA was not able to login the user in offline mode.
I work on Program.cs
with AddMsalAuthentication and save the tokens and ID's in local storage with help of MSAL
.
If I'm online everything works like expected and I can login with the users and the tokens will be stored in local storage.
After changing the online state, the PWA try to get the openid-configuration data from azure.
I tried to also serve this request with the service worker, which worked quite fine but the token request after that fails also.
I searched and found the CarChecker app and the docs as well but this didn't solve my problem.
Did I missed something or is there really no way, to make offline auth workable on Blazor Standalone PWA's?
question from:
https://stackoverflow.com/questions/65643124/blazor-standalone-pwa-offline-authentication-authorization-with-aad 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…