Defining Conditions

An Action Module can be configured with one or more conditions. Conditions are a powerful way to:

Setting a Condition

  1. Click on the Add/Remove button of the Condition section.

  2. Browse through the attribute selection menu and select the root object attribute or child object attribute to set a condition on.
    A new attribute is added to the Users Conditions list.

  3. Click on the Condition cell of the attribute row and select the condition operator.
    Note: The available condition operators depend on the attribute type (number, string, date, ...).

  4. Click on the Desired Value cell of the attribute row and enter the value for this condition in the Argument window.



    Note: The desired value can be static or dynamic. For more information about dynamic values, see: Using_Dynamic_Values.

  5. If the condition you configured points to a child object (for instance Local Drives, Processes or Software Products), you may need to change the Condition Scope.
    The condition scope controls whether the conditions should be applied to one or more instance of the child object or to all instances of the child object.

    Example 1
    - Reporting machines which have Microsoft Office installed

    > Add the condition:
    Computer Condition.Software Products.Product Name ::  Contains  :: Office
    > Select the condition, click on the
    Set Scope button, and select: Only one or more instances of Program must pass the condition for the computer object to be accepted.


    Example 2
    - Reporting machines which DO NOT have Microsoft Office installed

    > Add the condition:
    Computer Condition.Software Products.Product Name ::   NOT=   :: Office
    > Select the condition, click on the
    Set Scope button, and select: All instances of Program must pass the condition for the computer object to be accepted.

                 

     

  6. Repeat Steps 1 thru 4 to configure additional conditions.

    Note: Most attributes can be selected multiple times for conditions. For instance, you can configure the two conditions:  User.Password Age > 30 and User.Password Age < 60.
    If you have two or more conditions, they must all be true for the object to pass. This means that you cannot set conditions like:  User.Password Age = 0 OR User.Password Age > 120.

To remove a condition, select it from the list and click on the button or press the [DEL] key.

Using Conditions to Detect Objects

One primary purpose of a Condition is to detect objects with a particular configuration.

Examples

Reporting all machines equipped with Microsoft Office Standard 2007

Reporting all machines with one or more local hard drive with less than 5GB of free disk space.
 

Using Conditions to Target Specific Child Objects

Another purpose for a Condition is to target a specific child object. By definition, a root object (a computer, user or group) will have one or more instances of a child object (i.e., computer drives, services, processes, etc.).

If you configure a Set or Execute action on a child object, the action is applied to all instances of that child object. If you want to only execute the action on a particular instance of the child object, you need to configure a condition to isolate this instance from the set.  Since most Execute actions allow you to specify a child object instance name, this is rarely needed. However, in some advanced cases, it can be useful.

Examples

Disabling the Guest Account on all machines

Disabling computer local accounts is one action which can only be done using a condition. This is because the Scope Action > Computer > Local Account Database > Local User category doesn't include a method which allows you to disable a specific account name. However, it allows you to set the value of the Account Disabled attribute of a local user object.

If you were to simply add the set action: Set Computer Property > Local Account Database > Local Users > Account Disable :: = :: TRUE with no condition, all local users in the account database would be disabled. To target only the guest account, add the following condition:

For a more advanced example which uses these types of conditions, see: Example: Controlling the Local Administrators group's memberships