Why does the page automatically redirect to "/Account/Login" when the user is not authorized? #58848
Labels
area-blazor
Includes: Blazor, Razor Components
✔️ Resolution: Answered
Resolved because the question asked by the original author has been answered.
question
Status: Resolved
I have created a Blazor Web App project in auto render mode and added a nuget package Microsoft.AspNetCore.Authorization in version 8.0.10.
But when I added
[Authorize]
attribute to my page, I don't know why that it will automatically redirect to "/Account/Login" when the user is not authorized, even though there is no handler for this route. I would like the page to redirect to "/auth/signin" instead, what should I do?My dotnet version is 8. I develop it in Visual Studio 2022.
Thank you for your time and assistance.
PS: I will upload my code later.
The text was updated successfully, but these errors were encountered: