Skip to content

Is it really correct that I get "Authorization failed" message when not logged in? #37394

@kristofferjalen

Description

@kristofferjalen

I created a Visual Studio project from the Blazor WebAssembly App template, with Authentication type enabled (set to something else than "Anonymous"). Without any modifications, running the application I get message in the console:

info: Microsoft.AspNetCore.Authorization.DefaultAuthorizationService[2]
      Authorization failed. These requirements were not met:
      DenyAnonymousAuthorizationRequirement: Requires an authenticated user.

Yes, I am not logged in, but should I see that there is a component that is expecting an authenticated user? Is this log message by design?

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-blazorIncludes: Blazor, Razor Componentsfeature-blazor-wasmThis issue is related to and / or impacts Blazor WebAssembly

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions