I used Jwt authentication in a Blazor Client Hosted project with roles and everything (using Identity), But when I do the same thing in Blazor Server side It doesn't work, For example After I set the token in the Header:
client.DefaultRequestHeaders.Add("Authorization", $"Bearer {Model.Token}");
Console.WriteLine($"Is authenticated = {httpContext.HttpContext.User.Identity.IsAuthenticated}");
IsAuthenticated returns false, and when I navigate to home page (to cause a refresh) the IsAuthenticated still returns false and No user name is accessible through HttpContext.User.Identity.Name!! Is there a workaround for this. (the default authentication in Blazor serverside preview 6 is limited for Localization and other things and I don't want to use it)