Crdl
Blazor Web Assembly (stand alone) - [Authorize] Attribute not recognising roles straight after login
Could be worth putting some breakpoints into devtools https://github.com/dotnet/aspnetcore/blob/3d13fae15873da334bbff2371b6892346a931093/src/Components/WebAssembly/Authentication.Msal/src/Interop/AuthenticationService.ts#L37C11-L37C28
49 replies
Blazor Web Assembly (stand alone) - [Authorize] Attribute not recognising roles straight after login
I was thinking that
GetAuthenticationStateAsync
could be being called before everything is set up.. but actually if it's just fetching from JS then I have no idea49 replies
Blazor Web Assembly (stand alone) - [Authorize] Attribute not recognising roles straight after login
Hmm, not sure if necessarily a bug. We've not used
RemoteAuthenticationService
internally we've just inherited from AuthenticationStateProvider
directly49 replies
Blazor Web Assembly (stand alone) - [Authorize] Attribute not recognising roles straight after login
https://github.com/dotnet/aspnetcore/blob/main/src/Components/WebAssembly/WebAssembly.Authentication/src/Services/RemoteAuthenticationService.cs#L104 could it be this
useCache
flag?49 replies
Blazor Web Assembly (stand alone) - [Authorize] Attribute not recognising roles straight after login
49 replies