A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/dotnet-architecture/eShopOnContainers/issues/1495 below:

Basket.API project failed to use ByPassAuthMiddleware · Issue #1495 · dotnet-architecture/eShopOnContainers · GitHub

If the authentication center identity.API is not enabled,
when using the manual default user test, the Claim is reported as an error.

Because when we add a test user in the middleware(file : /src/Services/Basket/Basket.API/Infrastructure/Middlewares/ByPassAuthMiddleware.cs), the claim Type of the user Name is 'name':

new Claim("name", "Test user"),
new Claim("http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname","User"),

But in BasketController CheckoutAsync method, using ClaimType is (http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name),

var userName = this.HttpContext.User.FindFirst(x => x.Type == ClaimTypes.Name).Value;

the two do not match.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4