Custom requirements provide more flexibility than a predefined requirement. For example, you can add an application that is not included in the predefined lists of applications.
To build a custom requirement, you add one or more functions or IF..THEN statements to a script. When you run the script, the Host Integrity check looks for the condition that is listed under the IF node. Depending upon the condition, the action that is listed under the THEN node is executed. The result (pass or fail) is returned.
When you add many different conditions in one script to check for, this setting applies to the entire custom requirement script. This choice may affect whether you want to create several small custom requirements or a longer one that includes multiple steps.
To write a customized requirement script
In the console, open a Host Integrity policy.
On the Host Integrity policy page, click Requirements > Add.
In the Add Requirement dialog box, click the Select requirement drop-down list, select a predefined requirement, and then click OK.
For version 12.1.x, click Mac only if your Mac clients have installed the Symantec Network Access Control On-Demand Client.
In the Custom Requirement dialog box, type a name for the requirement.
The requirement name appears on the client computer. The name notifies the user whether the requirement has passed or the requirement has failed or prompts the user to download the software.
To add a condition, under Customized Requirement Script, click Add, and then click IF..THEN.
If you first add a function or an IF..THEN statement without filling out the fields, an error appears. If you do not want to add the statement, right-click the statement and click Delete.
With the highlight on the empty condition under the IF node, in the right pane, select a condition.
The Host Integrity check looks for the condition on the client computer.
Under the Select a condition drop-down list, specify the additional information that is required.
Under Customized Requirement Script, click THEN, and then click Add.
The THEN statement provides the action that should be taken if the condition is true.
Click any of the following options:
Use a nested IF..THEN statement to define conditions to check and actions to take if the condition is evaluated as true.
Use a function to define a remediation action, such as downloading a file.
Use a return statement to specify whether the results of the evaluation of the condition pass or fail. Every custom requirement must end with a pass or fail statement.
Use a comment to explain the functionality of the conditions, functions, or statements that you add.
In the right-hand pane, define the criteria that you added.
For more information on these options, click Help.
To add more nested statements, conditions, or functions, under Customized Requirement Script, right-click the node, and then click Add.