Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

BlazorWasm hosted - Identity issue with roles

$
0
0

I am trying to have Blazor WASM hosted app with asp.net core Identity. To keep it clear I created a repo where initial commit is pure blazor web app (.NET8) with WASM option + individual accounts. Its working for authorize view without any roles or claims. Second commit is after updating classes and connection string to use roles from existing database (identity).

https://github.com/Laftek/BlazorAppWasmAuth

What happens is that after viewing /weather page with "Admin" role it redirects me to login. After clicking weather link again it shows me weather forecast for few second (so roles authorization works) but then after few seconds it redirects me to login again. I cannot track where is this request coming from and its too difficult to me to investigate whole authorization/authentication process. What do I do wrong?

Thank you.


Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>