Additionally, I would like to configure the layered ABP solutions to authenticate using the main authentication system in the microservice >solution. I've already updated the authentication URL in the host's appsettings and the Angular environment file, but errors appeared and >redirection is not working properly. What are other changes or configurations I need to make to accomplish this?
Looking forward to your input!
i m asking about the auth issue please.
How can i make the layered ABP solutions (that will be my services) authenticate using the main auth existing in the main (microservice solution), not its existing auth?
Additionally, I would like to configure the layered ABP solutions to authenticate using the main authentication system in the microservice solution. I've already updated the authentication URL in the host's appsettings and the Angular environment file, but errors appeared and redirection is not working properly. What are other changes or configurations I need to make to accomplish this?
thanks, but what about this issue please?
Any update please?
Thanks for your advice.
I've made some adjustments to my architecture as follows:
For the microservice solution, I'll use a shared database, and for each layered ABP solution, I'll create a separate database for each tenant.
Is this approach okay for now?
Additionally, I would like to configure the layered ABP solutions to authenticate using the main authentication system in the microservice solution. I've already updated the authentication URL in the host's appsettings and the Angular environment file, but errors appeared and redirection is not working properly. What are other changes or configurations I need to make to accomplish this?
Looking forward to your input!
I have two questions plz:
1- How can we specify which service tenant database a microservice should work with (e.g., Microservice_Tenant1_Products, Microservice_Tenant2_Products, etc.)?
2- When we add new database migrations at the service, how should we handle them considering that each tenant has its own separate service database? how this migration will be applied to all service tenant dbs?
and if i have an EditionId, how to get the features related to it?
ABP Framework version: v9.0.4
Hi,
We are currently working on a solution that involves Editions, where each Edition should include specific Features. These Features are to be represented as service modules in our architecture. We intend to set up dynamically a separate database for each tenant for every service module they are using.
What is the best practice to implement this please?
Thanks
i fixed the error by adding
ValidateAudience = false
and now policy.RequireAuthenticatedUser();
is working fine
but when i used
policy.RequireRole("Admin");
i get 403 error
plz advise.
We are using a new microservice solution with YARP. What i want to do exactly is adding authentication and authorization on my gateway, so i added an AuthorizationPolicy on the route i want to secure (wanna configure the authorization policy by providing the AuthorizationPolicy value in the route configuration)
"Routes": { "order": { "ClusterId": "order", "AuthorizationPolicy": "authenticated", "Match": { "Path": "/api/order/{**catch-all}" } },
and also i want to use a custom policy
i added
app.UseAuthentication(); app.UseAuthorization();
and
context.Services.AddAuthorization(options => { options.AddPolicy("authenticated", policy => policy.RequireAuthenticatedUser()); });
but raised error related to authentication, and when i added
context.Services.AddAuthentication("Bearer") .AddJwtBearer(options => { options.Authority = "http://localhost:44349"; options.RequireHttpsMetadata = false; options.Events = new JwtBearerEvents { OnAuthenticationFailed = context => { var exception = context.Exception; Console.WriteLine($"Authentication failed: {exception.Message}"); return Task.CompletedTask; }, OnTokenValidated = context => { var token = context.SecurityToken; Console.WriteLine($"Token validated: {token}"); return Task.CompletedTask; } }; });
raised error related to invalid audiance
Please i want an example on the correct way to configure the authorization policy by providing the AuthorizationPolicy value in the route configuration.
Hello,
We are looking to implement authorization for an API Gateway. Specifically, I am interested in integrating YARP with ABP, with a focus on managing authentication.
Could you provide guidance on the best approach for integrating YARP with ABP to handle authentication, particularly for token-based systems such as JWT? I am also looking for best practices or sample code, particularly on how to securely add and use AuthorizationPolicy(default , anonymous, custom policy..) in the context of an API Gateway.
Any documentation or sample code to assist with this process would be greatly appreciated.
Thanks