- ABP Framework version: v8.3.1
- UI Type: Blazor WASM / Blazor Server
- Database System: EF Core (SQL Server)
We need to implement Oauth segregated by Tenant.
I looked into using https://abp.io/modules/Volo.OpenIddict.Pro but it does not seem to support this.
I found a partial solution in this question but it's missing a lot of details. https://abp.io/support/questions/4404/How-to-enable-Openiddict-for-multitenant
Can you provide some guidance on how to accomplish this?
Thanks so much.
1 Answer(s)
-
0
Hello, I have reviewed your question, but your question seems very general, so I will try to explain the rough steps of how to do it.
Here are the steps:
1-) Replace the OpenIddict Source Code
You can do this through ABP Studio as in the picture below:
2-) Extend each OpenIddict entity (Application, Authorization, Scope, Token) with TenantId and implement IMultiTenant. Ensure your DbContext includes these modified entities, and run migrations to add the TenantId columns. This ensures you have the database schema that contains a TenantId column and, importantly, uses ABP’s multi-tenancy filtering.
You can basically follow these two steps. Afterwards, if you have a problem with this, if you can forward the log record directly, we can proceed more concretely from there.