In our multi tenant SaaS software application we intended to use Microsoft Identity Platform (Azure AD) for user authentication and providing the claims for authorization within the application. We are facing a lot of difficulties managing and getting the correct claims throughout the stack and are now considering providing our own identity and web tokens (through a library like Microsoft.AspNetCore.Identity
).
This means we would still rely on Azure AD for the authentication, but then use our own (synchronised) identities to manage application roles, permissions, etc and store these in the application database.
Q: What are the security risks we will be exposed to when we provide our own identity rather than use a service for these, keeping in mind we would still use a service for the authentication?