Custom Authorization Provider is a structure used to create a customized authentication and authorization system. It is used to determine the user's roles within the application and allows you to determine which roles users have on the web or mobile side at the opening of each screen within the application by taking from different systems (for example, Azure, custom databases, etc.).
You can follow these steps to create Custom Authorization Provider:
The Custom Authorization Provider you created represents a C# class that manages user authentication and authorization.
Kuika provides a ready-made C# predefined function in Custom Authorization for the user. This function contains the following methods and variables:
The Get Roles method returns which roles the user has in the application. This method takes the following parameters:
return null; This line should be used if this particular authentication system does not want to customize application roles. In this case, the default system behavior is preserved and no custom role is assigned to the user.
The comments provided in the code contain important information about how the code should be used. In particular, they indicate that if it is desired to define developer-specific roles, the relevant script should be opened and the list of appropriate roles should be inserted instead of the code fragment specified here.
It can be used to customize the authentication and authorization processes of an application. For example, you may want to define special roles for workers on a particular screen or application partition. This class can be used to meet such requirements and provides developers with a starting point for customizing roles.