Unofficial Content
  • This documentation is valid for:

Suppose a scenario where you have developed a Smart Devices application that is already running on different devices.

You need to change the main Smart Devices object of the KB (for example, change it from being an SD Panel to a Dashboard Object), but you do not want to change the GAM Application, because:

  1. Conceptually, it is the same Application, although the entry point changes (the main SD object). 
  2. The Permissions grouped to the new Application will be the same of the old Application. 
  3. You do not want the users to be aware of the change. If the GAM Application changes, they will be forced to login again (although they could have logged in the old Application).

Solution

The solution is to change the Client Id and Client Secret information of the new Application to be the same as the former Application.

In detail, suppose the old Application is SDPanel (which is a main SD object), and the Security Client ID property = X and Security Client Secret property = Y.
Now you create another object, named Dashboard1 (which is a main SD object) which is going to replace SDPanel.

In that case, Dashboard1 needs to have the same credentials as SDPanel, so you need to set the same values for Security Client Id property and Security Client Secret for Dashboard1.

In sum, you need to follow these steps:

  1. Get the Security Client ID property and Security Client Secret property values of SDPanel.

    SecurityClientIdClientSecretProps
     
  2. Change those values for any other pair of values. In order to edit these properties, execute the Update client Id and Client secret option.
     
  3. Edit the Dashboard1 properties, and change the Security Client Id, and Security Client secret properties, with the values which SDPanel used to have. In order to edit these properties, execute the Update client Id and Client secret option.

    DashboardUpdateSecurityProps
    Note that this dialog is deprecated since upgrade 4 of Genexus XEv2, where you can edit the properties as usual.
     
  4. Build the Application.

    After build, you will have both GAM Applications in GAM database. What is really important is that Dashboard1, as it keeps the same Client Id and Client Secret information as SDPanel used to have, keeps also all the Permissions which had been defined for SDPanel.

Note

It is important to note that, if you change the Client Id and Client Secret information of an Application, the Automatic Permissions generated by GeneXus for that Application will be generated again, but the Permissions created by the user which used to belong to that Application are lost.

In the previous example, if you have SDPanel as the main object, and the Security Client ID property = X and Security Client Secret property = Y. If you want Dashboard1 to be the new main SD object, and not lo lose the Permissions defined for the Application, you need to set Security Client ID property = X and Security Client Secret property = Y for Dashboard1 also, as stated previously in this document.

See Also

Secure Native Mobile applications architecture

Last update: February 2024 | © GeneXus. All rights reserved. GeneXus Powered by Globant