Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
569 views
in Technique[技术] by (71.8m points)

azure active directory - Blazor Standalone PWA offline Authentication/Authorization with AAD

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

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...