This page allows you to modify the settings for the serial validation of your package.
The recommended way is to use you own validation method. For better protection the validation should be done by the application itself, instead of the MSI package. Read more here: Serial Validation.
This is the template that will be used to generate the serials. The syntax for template is: <XXX..-XXX..-...> where X is either the # character or the ? character.
- # - stands for a digit.
- ? - stands for a digit or letter.
<###-???-??> - is a template for a serial containing three groups of characters. The first group contains only digits while the last two groups can contain both digits and letters.
For user-defined validation method the template doesn't have to respect this exact syntax. It may have any value accepted by Windows Installer.
In case of algorithm verified serials it is strongly recommended that you use a template with a large number of characters.
Predefined Set of Serials
This is a list of the serials that will be valid for this package. It must contain at least one serial number. Use the “Add” button to add a serial to the list. Use the “Remove” button to delete a serial from the list. Use the “Save...” button to save the current list of serials to a text file. If the file already exists, it's content will be overwritten. Use the “Load...” button to load in the current project a list of serials and their template from a text file.
Please note that loading serials from the file will delete any existent template and serials from the project.
Algorithm Verified Serials
This is the seed for the algorithm verifying the serials. The seed is a special value used as an input for the algorithm. Use the “Reset” button to generate a new value for the seed. You might need a new value if, for example, you release a new version of your product and don't want the serials for the old version to unlock the current version.
Use the “Save...” button to save a list of serials to a text file. The Save Serials Dialog will appear allowing you to specify the number of serials to be generated.
This option allows you to validate the serial number entered by the user with your custom validation algorithm implemented on your web server.
The Configure server-side serial number validation How-To explains how to use this method.
The Advanced Installer validation tool will POST a web form containing the data collected from the installing user, such as: serial number, user name, company, product version, and system language id.
The following POST variables will be available for you to use in your server-side validation script:
- sn - retrieved from the PIDKEY Windows Installer property.
- username - retrieved from the USERNAME Windows Installer property.
- company - retrieved from the COMPANYNAME Windows Installer property.
- email - retrieved from the EMAIL Windows Installer property.
- version - retrieved from the ProductVersion Windows Installer property.
- languageid - target computer's system language ID.
- ai - retrieved from the ADD_SV_INFO Windows Installer property.
The language identifier is useful if you want the script to return a localized message.
This information is automatically collected for you by the built-in dialog UserRegistrationDlg, but you can choose to set the above mentioned Windows Installer properties by any means you see fit.
The Email field does not exist on the UserRegistrationDlg dialog and must be manually added.
The script must give an answer, so the Advanced Installer validation tool can choose the following course of action. The answer must be in the form:
"Message" is an explanatory message, "\n" is the new line character and "AnswerCode" must be one of:
- 601 - Serial number is valid. The Advanced Installer validation tool will allow the installation to continue. If an SKU needs to be selected then the "Message" should contain the desired SKU ID or name.
- 602 - Serial number is invalid. The Advanced Installer validation tool will not allow the installation to continue and will display a message box containing the explanatory message provided by your server.
Optionally, you can return a custom AnswerCode in case you consider the received serial number as valid and want to dynamically change the course of installation according to this response. The AnswerCode sent by the server after the validation will be available by accessing the Windows Installer property AI_SERVAL_RESPONSE_CODE. For example, you can choose to conditionally install a feature based on the response code received from your server-side validation script; you could have several classes of valid serial numbers and your installation package can deploy differently depending on which serial number the user has entered.
You must provide a URL to your serial number validation script page. Enter it in the "URL" field.
If the targeted computer for installation does not have internet connectivity, the provided URL is incorrect or the web sever does not respond in a timely fashion with the appropriate message format, the Advanced Installer validation tool will not allow the installation to continue.
Here are some simple server script examples: one using PHP, and another using JSP, both over a MySQL database. You can further customize this script according to your requirements.
User Defined Validation DLL
This option allows you to specify you own serial validation procedure. In this case the template may have any structure that you require.
Use the “...” button to select a DLL. You can edit the name of the function that performs the validation in the “Validation Function Name” field. Also, Advanced Installer automatically detects the functions that the DLL exports, so you can choose the desired function from the drop-list.
For an example of how to design your own validation DLL see Serial Number Validation DLL.
- Expression - a boolean expression which must be true for the serial validation to be executed. Edit this field using Smart Condition Edit Control.
The condition you set will be reset if the UI theme is changed.
If you change the serial validation method or the template from one version of your product to another, it is recommended to save a back-up copy of the project. This is because the data about the serials is stored in the project (AIP) file. If you overwrite that data you cannot retrieve it.
The serials are case-sensitive, so if , say, "ABC-123" is a valid serial, "abc-123" is not.
For details about the functioning of the serial validation methods used in Advanced Installer see Serial Validation.
- Save Serials Dialog
Specify the file and the number of serials that should be added to this file.