K2BTools Basic Security Procedures Personalization

When K2BTools is first used in a GeneXus Knowledge base, several objects (called Basic Objects) are imported. One of these objects is the default Master Page for the application, and some procedures and Web Panels called by it.

The objects called by the Master Page are meant to implement logic related to the user Session, such as getting the active user, or logging out. The objects are empty when they are first imported.

The GAM integration module provides an implementation for these objects that calls the GAM module to perform the appropriate actions.

If you are not using the GAM integration module, the following objects should be implemented in order to integrate your module with your master page:

  • K2BGetUserCaption (procedure): Returns the name of the user, that will appear on the "My Account" menu inside the master page.
  • K2BIsAuthenticated (procedure): Returns true if the user is authenticated, false otherwise. If the user is not authenticated the master page will call the K2BNotAuthorized web panel. By default it always returns true.
  • K2BChangePassword (webpanel): Is the webpanel that implements the "change password" feature. This panel should include the feature's implementation or call another Web Panel that does so.
  • K2BLogOut (webpanel): Is the webpanel that implements the logout feature. This panel should include the feature's implementation or call another Web Panel that does so.
  • K2BGetUserMenu (procedure): Is a procedure that load the application menu (return a K2BMultiLevelMenu SDT). This procedure should be called from the application master page.
  • K2BGetUserCode (procedure): Is a procedure that returns the current user code. The User Preferences Persistence Module uses it to determine which user is changing the configuration. 
  • K2BGetTenantCode (procedure): Is a procedure that returns a tenant code. If the application is not multi tenant, an empty value should be returned. It is used by the User Preferences Persistence Module. When user changes its preferences the value returned by the procedure will be stored in the TenantCode field.