Skip to content

Blazor Wasm AAD B2C authentication issue #28969

@ismailhozza

Description

@ismailhozza

Describe the bug

Hi, I am struggling with the below error. Can't figure out the root cause. I have a Blazor Wasm application with AAD B2C authentication. Login works fine, but after some time I get the below error. Any ideas what could be the problem?

image

Based on the console logs, it seems that ID token is undefined.

ClientAuthError: null_or_empty_id_token: The idToken is null or empty. Please review the trace to determine the root cause. Raw ID Token Value: undefined

Further technical details

  • Dotnet version: 5.0.100
  • Project dependencies

`

<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="5.0.1" PrivateAssets="all" />

<PackageReference Include="Microsoft.Authentication.WebAssembly.Msal" Version="5.0.1" />

<PackageReference Include="Microsoft.Extensions.Logging.Configuration" Version="5.0.0" />

<PackageReference Include="System.Net.Http.Json" Version="5.0.0" />

`

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions