Activities of "maliming"

hi

Can you try to prepare a template project and apply your code to reproduce?

: )

hi buraksahin94

https://abp.io/support/questions/7774/Login-Sayfas-Hakknda-Bilgi#answer-3a14fc7b-299a-5fd8-5dcd-a4534a96d4bc

hi @oguzcekin

Have you tried to change the responseType from code to password?

hi

I don't have the schema. We just use EF Core migration.

hi

it redirect to login page for Blazor. I need redirect to login page with Angular.

You are using the code flow. This is recommend way.

However, you can change it to password flow.

https://abp.io/docs/latest/framework/ui/angular/authorization?_redirected=B8ABF606AA1BDF5C629883DF1061649A#authorization-code-flow

The values of currentUser come from the claims.

https://github.com/abpframework/abp/blob/dev/framework/src/Volo.Abp.Security/Volo/Abp/Users/CurrentUser.cs#L14-L34

https://github.com/abpframework/abp/blob/dev/framework/src/Volo.Abp.AspNetCore/Volo/Abp/AspNetCore/Security/Claims/HttpContextCurrentPrincipalAccessor.cs

Based on your claim type, you can set AbpClaimTypes like below:

AbpClaimTypes.UserName = JwtClaimTypes.PreferredUserName;
AbpClaimTypes.Name = JwtClaimTypes.GivenName;
AbpClaimTypes.SurName = JwtClaimTypes.FamilyName;
AbpClaimTypes.UserId = JwtClaimTypes.Subject;
AbpClaimTypes.Role = JwtClaimTypes.Role;
AbpClaimTypes.Email = JwtClaimTypes.Email;

I have an article you can check https://abp.io/community/articles/how-claim-type-works-in-asp-net-core-and-abp-framework-km5dw6g1

hi

Please update your EF Core migrations and update the database.

hi

So, given the scenario, how exactly can I set these granted policies and the currentUser values in the application when the user logs in?

Can you set a breakpoint after Authentication to check the claims of the HttpContext.User first?

app.UseAuthentication();
app.UseAbpOpenIddictValidation();

app.Use(async (ctx, next) =>
{
    //check the claims of the HttpContext.User
    await next(ctx);
});

The values of currentUser come from the claims.

https://github.com/abpframework/abp/blob/dev/framework/src/Volo.Abp.Security/Volo/Abp/Users/CurrentUser.cs#L14-L34

https://github.com/abpframework/abp/blob/dev/framework/src/Volo.Abp.AspNetCore/Volo/Abp/AspNetCore/Security/Claims/HttpContextCurrentPrincipalAccessor.cs

hi

We have no experience in this case.

You can implement such a feature in EF Core, and then ABP will be automatically compatible with it, because ABP completely uses EF Core as the data source.

If you have any problem with this feature and abp. You can give feedback here.

Thanks.

Showing 3871 to 3880 of 11558 entries
Learn More, Pay Less
33% OFF
All Trainings!
Get Your Deal
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.1.0-preview. Updated on December 25, 2025, 06:16
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.