Custom Authentication Provider

Custom Authentication Provider, is a special or customised authentication provider. Generally, it is suitable for standard authentication solutions, but for some special requirements or functions, standard authentication methods may be insufficient. Therefore, a customised authentication provider is a specially created structure to authenticate users and ensure security.

To create Custom Authentication Provider, open Datasources view mode via Header. On the screen that opens, click the + icon on the left panel. Then select C# from the Select Type field.

Name the Datasource you created. Select Custom Authentication Provider from the Selectbox and click the Create button.

The generated Custom Authentication Provider is opened with a predefined class. This code contains a C# class and an instantiation of a class that implements a custom authentication provider. This class provides customised functionality for user authentication and contains comments to describe this functionality.

The Custom Authentication class implements the Custom Authentication interface. This interface defines the authentication functions.

In the code, Login, Refresh Token, Find Manager and Logout methods are provided ready for users.

  • Login method allows users to log in. There are two different versions: one for login with username and password and one for login with username, an external token and a refresh token. Within the login method, the user's login process must be validated. This verification can be done from fields such as Rest API or Custom DB. Additions should be made to the code in this direction.
  • Refresh Token method is used to refresh an expired Token.
  • Find Manager method is used to find the manager of a user. There are descriptions of how this function can be customised. This method can be used frequently in Process Automation.
  • Logout method allows a user to log out of the system. Comments are provided to customise this method. The logout method has no return value.

In Custom Authentication Provider, areas where return null values are not returned are valid. The values in the quika are considered invalid, and the values in the quika are valid where return null is returned.

The explanations are written to facilitate the use and customisation of the code. They are included to guide developers who want to customise the user authentication of the code. In this way, developers can use this code to implement the authentication logic of a particular application or system as they wish.