Licence management

  1. licencefile - licence generation program on apps1 should have the subject line of the format: licence file for __domain__created by __userid__.
  2. licencefile - licencefile should have hostname in the list of its fields.
  3. There should be scripts to carry out the process of licence installation and licence validation. They are as follows:
    1. licence_install - This script will take one argument - path of the licencefile. This script will install the licencefile at its correct location and call licence_check. licence_check will validate the licence and return the status. As per the status a message will be displayed to the user saying licence is valid or invalid.
    2. licence_check - This script will validate the licence and return the status of validation.
  4. Whenever licencecheck runs it should connect to the database and see if there is any user other than the system created user admin who has admin privileges. If there is no such user then validate the licence and show the username and password of the system admin. If there is a user other than admin who has administrative privileges, then just validate the licence and say ok or error.
  5. licencecheck - In the current scenario the following is the sequence of checks:
    1. Check the sitekey in the licencefile against the sitekey generated by sitekeygen. If not same then exit with error.
    2. Check if the current data is within the limits of the licence created timestamp and the licence expiry timestamp. If not then exit with error.
    3. Check the signature. If not valid then exit with error.

    This sequence needs to be changed with the signature check being carried out first along with a review of this code.