Cisco Guard Configuration Guide (Software Version 5.0)
Configuring Zones

Table Of Contents

Configuring Zones

Overview

Creating a Zone

Creating a New Zone

Duplicating a Zone

Configuring Zone Attributes

Learning the Zone Traffic Characteristics

Understanding the Learning Process

Understanding the Protect and Learn Function

Synchronizing the Zone Learning Process Results with a Cisco Traffic Anomaly Detector

Constructing Policies

Tuning Thresholds

Configuring Learning Parameters

Configuring Periodic Actions

Configuring the Threshold Selection Method

Marking the Policies as Tuned

Tuning Zone Policy Thresholds and Enabling Zone Protection Simultaneously

Synchronizing the Zone Configuration in the Guard with the Cisco Traffic Anomaly Detector

Configuration Guidelines

Synchronizing the Zone Configuration Offline

Example Scenario

Protecting the Zone

Activating Zone Protection

Protecting the Entire Zone

Protecting an IP Zone that is Part of the Zone Address Range

Protecting an IP Address when the Zone Name is Not Known

Deactivating Zone Protection

Configuring How the Guard Performs Zone Protection

Configuring the Activation Method

Configuring the Activation Extent

Understanding Subzones

Configuring the Protection Inactivity Timeout

Enabling On-Demand Protection


Configuring Zones


This chapter describes how to create and manage zones on the Cisco Guard (Guard). These procedures are required to enable zone protection.

This chapter contains the following sections:

Overview

Creating a Zone

Configuring Zone Attributes

Learning the Zone Traffic Characteristics

Tuning Zone Policy Thresholds and Enabling Zone Protection Simultaneously

Synchronizing the Zone Configuration in the Guard with the Cisco Traffic Anomaly Detector

Protecting the Zone

Enabling On-Demand Protection

Overview

A zone is a network element that the Guard uses to protect against DDoS attacks. A zone can be a network server, client, or router; a network link, subnet, or an entire network; an individual Internet user or a company; an Internet Service Provider (ISP), or any combination of the above. The Guard can protect different zones simultaneously as long as their network address ranges do not overlap.

You assign a name to the zone and use this name to refer to it.

The zone configuration process consists of the following tasks:

Creating a zone—You can create a zone and configure the zone name and the zone description. See the "Creating a Zone" section for more information.

Configuring the zone network definition—You can configure the zone network definitions that include the network IP address and subnet mask. See the "Configuring Zone Attributes" section for more information.

Configuring the zone filters—You can configure the zone filters. The zone filters apply the required protection level to the zone traffic and define the way the Guard handles specific traffic flows. See Chapter 6, "Configuring Zone Filters," for more information.

Learning the zone traffic characteristics—You can create the zone protection policies that enable the Guard to analyze a particular traffic flow and take action if the traffic flow exceeds a policy threshold. The Guard constructs the policies in a learning process that consists of two phases: policy construction and threshold tuning. See the "Learning the Zone Traffic Characteristics" section for more information.

Creating a Zone

You can create a zone and configure the zone name, description, network address, operation definitions, and networking definitions.

When you create a new zone, you can use an existing zone as a template or you can create a zone from system-defined zone templates. The zone template defines the initial policy and filter configuration of the zone.

The new zone has default policies that are tuned for on-demand protection. However, if there is no immediate need to protect the zone, we recommend that you allow the Guard to learn the zone traffic characteristics. See the "Enabling On-Demand Protection" section for more information. Alternatively, you can copy the configuration of the zone and the zone policies from the Cisco Traffic Anomaly Detector.

You can create a new zone in three ways:

Create a new zone—You can create a new zone from system-defined zone templates. Use this method to create a new zone with the default policies and filters.

After you create a new zone, you must configure the zone attributes.

Duplicate a zone—You can create a zone from an existing zone. Use this method if the new zone has traffic patters that are similar to those of an existing zone.

Copy the zone configuration from the Cisco Traffic Anomaly Detector—You can enable synchronization of the zone configuration with the Cisco Traffic Anomaly Detector. See the "Synchronizing the Zone Configuration in the Guard with the Cisco Traffic Anomaly Detector" section.

You can initiate this action only from the Cisco Traffic Anomaly Detector. See the Cisco Traffic Anomaly Detector Configuration Guide for more information.

See the "Configuring Zone Attributes" section for information on how to modify the zone configuration settings.

Creating a New Zone

To create a new zone from system-defined zone templates, enter one of the following commands:

zone new-zone-name [template-name] [interactive]—Creates a new zone. If you do not insert the template-name argument, the new zone is created from the GUARD_DEFAULT zone template.

zone zone-name [template-name] [interactive]—Deletes the existing zone and creates a new zone with the same name.

When using a system-defined zone template, the Guard applies the default settings to all zone attributes. These default policy settings are tuned for on-demand protection.

If the command is performed successfully, the Guard enters the configuration mode of the new zone.

If you enter the name of an existing zone without specifying a zone template, the Guard enters the configuration mode of the specified zone.

Table 5-1 provides the arguments and keywords for the zone command.

Table 5-1 Arguments and Keywords for the zone Command 

Parameter
Description

new-zone-name

The name of a new zone. The name is an alphanumeric string from 1 to 63 characters. The string must start with an alphabetic letter, can contain underscores, but cannot contain any spaces.

zone-name

The name of an existing zone.

template-name

(Optional) A zone template that defines the zone configuration. The default is to create the zone using the GUARD_DEFAULT zone template.

See Table 5-2 for more information.

interactive

(Optional) Sets the Guard to perform zone protection in an interactive manner. The dynamic filters that the policies create appear as recommendations. You must decide whether or not to activate each dynamic filter. See Chapter 8, "Using Interactive Protect Mode," for more information.


Table 5-2 displays the zone templates.

Table 5-2 Zone Templates 

Template
Description

GUARD_DEFAULT

The default zone template. The Guard may change the packet source IP address to the Guard TCP-proxy IP address. You can use this zone template if you do not use IP-based Access Lists (ACLs), access policies, or load-balancing policies that are based on the incoming IP address for the zone network.

GUARD_TCP_NO_
PROXY

A zone template designed for a zone for which no TCP proxy is to be used. You can use this zone template if the zone is moderated according to IP addresses such as an Internet Relay Chat (IRC) server-type zone, or if you do not know the type of services running on the zone.

Bandwidth-limited Link Templates

The zone templates designed for on-demand protection of large subnets segmented according to zones with a known bandwidth. We recommend that you activate zone protection for these zones based on the attacked subnet or range by using the activation-extent ip-address-only command. We recommend that you define such a zone on the Cisco Traffic Anomaly Detector with a protect-ip-state of dst-ip-by-name.

The policy thresholds are tuned so that the Guard identifies an attack on the zone once the traffic rate to the zone exceeds the specified rate.

Bandwidth-limited Link Templates (continued)

The following bandwidth-limited link zone templates are available for 128 Kb, 1 Mb, 4 Mb, and 512 Kb links:

GUARD_LINK_128K

GUARD_LINK_1M

GUARD_LINK_4M

GUARD_LINK_512K

You cannot perform the policy construction phase of the learning process for zones that were created from these templates.


This example shows how to create a new zone:

user@GUARD-conf# zone scannet interactive 
user@GUARD-conf-zone-scannet#

To delete a zone, use the no zone command. When deleting a zone, you can use an asterisk (*) as a wildcard character at the end of the zone name. The wildcard allows you to remove several zones with the same prefix in one command.

To display the zone templates, use the show templates command in global or configuration mode. To display the zone template default policies, use the show templates template-name policies command in global or configuration mode.

Duplicating a Zone

You can create a new zone based on an existing zone. When using an existing zone as a template for the new zone, all properties of the existing zone are copied to the newly defined zone. If you specify a snapshot, the zone policies are copied from the snapshot.

To duplicate a zone, enter one of the following commands:

zone new-zone-name copy-from-this [snapshot-id]—Use this command in zone configuration mode to create a new zone with the configuration of the current zone.

zone new-zone-name copy-from zone-name [snapshot-id]—Use this command in configuration mode to create a new zone with the configuration of the specified zone.

Table 5-3 provides the arguments for the zone command.

Table 5-3 Arguments for the zone Command 

Parameter
Description

new-zone-name

The name of a new zone. The name is an alphanumeric string from 1 to 63 characters. The string must start with an alphabetic letter and can contain underscores, but cannot contain any spaces.

copy-from-this

Creates a new zone with the configuration of the current zone.

copy-from

Creates a new zone with the configuration of the specified zone.

zone-name

The name of an existing zone.

snapshot-id

The ID of an existing snapshot. See the "Displaying Snapshots" section on page 7-39 for more information.


The following example shows how to create a new zone from the current zone:

user@GUARD-conf-zone-scannet# zone mailserver copy-from-this 
user@GUARD-conf-zone-mailserver#

If the command is performed successfully, the Guard enters the configuration mode of the new zone.

The policies of the new zone are marked as untuned. We recommend that you perform the threshold tuning phase of the learning process to tune the policy thresholds to the zone traffic. If the traffic characteristics of the new zone are identical or very similar to the traffic characteristics of the originating zone, you can mark the policy thresholds as tuned. See the "Marking the Policies as Tuned" section for more information.

The activation interface of the new zone is set to zone-name-only, regardless of the configuration of the source zone. See the "Configuring the Activation Method" section for more information.

Configuring Zone Attributes

After you create the zone, you can configure the zone attributes.

To configure the zone attributes, perform the following steps:


Step 1 Enter zone configuration mode. Skip this step if you are in zone configuration mode already.

To enter zone configuration mode, enter one of the following commands:

conf zone-name (from global mode)

zone zone-name (from configuration mode or zone configuration mode)

The zone-name argument specifies the name of an existing zone.

Step 2 Define the zone IP address. You must define the IP address to enable the Guard to learn the zone traffic and protect the zone.

To configure the zone IP address, enter the following command:

ip address ip-addr [ip-mask] 

Table 5-4 provides the arguments for the ip address command.

Table 5-4 Arguments for the ip address Command 

Parameter
Description
ip-addr

The zone IP address. The zone can also be a subnet. Enter the IP address in dotted-decimal notation (for example, 192.168.100.1).

ip-mask

(Optional) The IP subnet mask. Enter the subnet mask in dotted-decimal notation (for example, 255.255.255.0). The default subnet mask is 255.255.255.255.


You must define at least one IP address before you can activate zone protection. You can add additional zone IP addresses and subnets at any time.

If you modify the zone IP address or subnet, perform one of the following tasks:

If the new IP address or subnet consists of a new service that was not previously defined in the zone network, activate the policy construction phase before activating zone protection or add the service manually. See the "Constructing Policies" section and the "Adding a Service" section on page 7-13 for more information.

If you enabled the protect and learn function, use the no learning-params threshold-tuned command to mark the zone policies as untuned. Do not change the status of the zone policies to untuned if there is attack on the zone because that prevents the Guard from detecting the attack, and causes the Guard to learn thresholds of malicious traffic. See the "Marking the Policies as Tuned" section for more information.

If you did not activate the protect and learn function and you do not plan to activate the protect and learn function, activate the threshold tuning phase before activating zone protection. See the "Tuning Thresholds" section.

Step 3 (Optional) Limit the traffic bandwidth that the Guard injects back to the zone according to the traffic rate that you think the zone can handle by entering the following command in zone configuration mode:

rate-limit {no-limit | rate burst-size rate-units}

We recommend that you set the bandwidth value to the highest bandwidth that was measured entering the zone. If you do not know what this value is, leave the default bandwidth value (no-limit).

Table 5-5 provides the arguments and keywords for the rate limit command.

Table 5-5 Arguments and Keywords for the rate limit Command 

Parameter
Description
no-limit

Specifies that the zone is defined with no rate limit.

rate

An integer greater than 64 that specifies the amount of traffic that is allowed to pass to the zone. The units are specified by the rate-units argument. The rate limit can be up to 10 times greater than the burst limit.

burst

An integer greater than 64 that specifies the highest traffic peak allowed to pass to the zone. The units are bits, kilobits, kilopackets, megabits, and packets that correspond to the rate units that are specified by the rate-units argument. The burst limit can be up to eight times greater than the rate limit.

rate-units

The rate units. The units are as follows:

bpsBits per second

kbpsKilobits per second

kppsKilopackets per second

mbpsMegabits per second

ppsPackets per second


Step 4 (Optional) Add a description to the zone for identification purposes by entering the following command in zone configuration mode:

description string

The maximum string length is 80 characters.

To modify a zone description, reenter the zone description. The new description overrides the previous description.

Step 5 Display the configuration of the newly configured zone by entering the show running-config command in zone configuration mode.

The configuration information consists of CLI commands that are executed to configure the Guard with the current settings. Refer to the specific command entries for more information.


The following example shows how to create a new zone and configure the zone attributes:

user@GUARD-conf# zone scannet
user@GUARD-conf-zone-scannet# ip address 192.168.100.34 
255.255.255.252
user@GUARD-conf-zone-scannet# rate-limit 1000 2300 pps
user@GUARD-conf-zone-scannet# description Demonstration zone

Learning the Zone Traffic Characteristics

This section describes how to use the Guard learning process to analyze zone traffic characteristics to create and fine-tune the policies that the Guard uses for zone protection.

This section contains the following topics:

Understanding the Learning Process

Understanding the Protect and Learn Function

Synchronizing the Zone Learning Process Results with a Cisco Traffic Anomaly Detector

Constructing Policies

Tuning Thresholds

Configuring Learning Parameters

Understanding the Learning Process

During the learning process, the Guard learns the normal zone traffic characteristics. The Guard uses the learning process results to create policies for zone protection. These policies instruct the Guard on how to handle the zone traffic flows.

After an initial learning process of constructing policies, you can activate the learning process and zone protection simultaneously. At the same time, the Guard tunes the policy thresholds and monitors the policy thresholds for traffic anomalies. This process enables the Guard to protect the zone, while constantly updating the policy thresholds according to the zone traffic characteristics, and prevents the Guard from learning malicious traffic thresholds.

To learn the zone traffic characteristics, the zone traffic must be diverted to the Guard. You must configure diversion before initiating the learning process, or divert the zone traffic to the Guard manually, using an external device. Configure zone diversion using the Guard routing configuration.

See Chapter 4, "Configuring Traffic Diversion" for more information.

The learning process consists of these two phases:

1. Policy Construction—The Guard creates the zone policies using the policy templates. The traffic flows transparently through the Guard enabling it to discover the main services that the zone uses. The new policies override the existing ones.

The policy templates are the Guard tools for constructing the policies. These templates define the types of zone policies that the Guard creates. The policy templates also define the maximum number of services that the Guard monitors closely and the minimum threshold that triggers the Guard to create new policies. To change the rules for constructing zone policies, change the policy template parameters before you initiate the policy construction phase. See Chapter 7, "Configuring Policy Templates and Policies," for more information.

2. Threshold Tuning—The Guard tunes the policies to fit the zone services traffic rates. The traffic flows transparently through the Guard, enabling it to tune the thresholds for the services that it discovered while constructing the zone policies. The new thresholds override the existing ones.

You can activate the threshold tuning phase and activate zone protection simultaneously (the protect and learn function) to prevent the Guard from learning malicious traffic thresholds. You can set the Guard to constantly tune the zone policies and define the intervals in which the Guard updates the policy thresholds.


Note When you activate the protect and learn function, the Guard constantly diverts the zone traffic to itself.


The Guard learns the zone traffic characteristics to acquire a basis on which to compare zone traffic and trace any anomalies that might become malicious. The Guard does not modify the current zone policies during the learning process and updates the policies when you decide to accept the results of one of the learning phases only. After the policies are created, you can add and delete policies or change policy parameters such as thresholds, services, timeouts, and actions.

You can back up the current zone policies at all times by using the snapshot threshold-selection cur-thresholds command. See the "Creating Snapshots" section on page 7-36 for more information.


Note During the learning process, the Guard drops packets if one of the following fields in the packet equals zero: source IP address, protocol number, UDP source or destination port, and TCP source or destination port.


If there is an attack on the zone before the learning process has been completed, use on-demand protection to protect the zone if one of the following conditions apply:

The zone is in the learning process.

You enabled the protect and learn function but the Guard has not yet learned the zone traffic characteristics.

You have accepted policy thresholds that you think that no longer represent the zone traffic.

See the "Enabling On-Demand Protection" section for more information.

You can enter learning-related commands for several zones at the same time. Enter the command in global mode and use an asterisk (*) as a wildcard. For example, to initiate the policy construction phase for all zones, enter the learning policy-construction * command in global mode. To accept the results of the policy construction phase for all Guard zones with names that begin with scan (such as scannet and scanserver), enter the no learning scan* accept command in global mode.

Understanding the Protect and Learn Function

After an initial learning process of constructing policies, you can activate the learning process and enable zone protection simultaneously using the protect and learn function. The Guard tunes the policy thresholds and at the same time monitors the policy thresholds for traffic anomalies. The protect and learn function enables the Guard to protect the zone, constantly update the policy thresholds according to the zone traffic characteristics, and prevents the Guard from learning malicious traffic thresholds.

Before you activate the protect and learn function, you can configure when and how the Guard accepts the results of the learning process by configuring the learning parameters.

See the "Tuning Zone Policy Thresholds and Enabling Zone Protection Simultaneously" section for more information.

Synchronizing the Zone Learning Process Results with a Cisco Traffic Anomaly Detector

You can configure a Cisco Traffic Anomaly Detector (Detector) to constantly learn the zone traffic and update the Guard with the zone policies.

When the Detector detects an attack on the zone, it stops the learning process, and activates the Guard to protect the zone, and resumes learning the zone traffic when the attack ends. This process enables you to tune the zone policy thresholds continuously, but refrain from constantly diverting the zone traffic to the Guard.

To synchronize the learning process results with a Detector, you must perform the following tasks:

1. Add the Guard to one of the Detector SSL remote Guard lists

2. Establish an SSL communication channel with the Detector (see the "Configuring SSL Communication Channels" section on page 3-23)

Create the zone on the Detector using a GUARD zone template You can synchronize the zone configuration with the Detector or configure the Detector to synchronize the zone configuration with the Guard automatically. See the "Synchronizing the Zone Configuration in the Guard with the Cisco Traffic Anomaly Detector" section for more information.

You can configure this option on the Detector only. See the Cisco Traffic Anomaly Detector Configuration Guide for more information.

Constructing Policies

In the policy construction phase, the Guard creates the zone policies using the policy templates. The traffic flows transparently through the Guard enabling it to discover the main services (ports and protocols) that the zone uses. You can configure the policy construction rules. For example, you can prevent the Guard from creating policies of a certain type by disabling the relevant policy template. To change the rules for constructing zone policies, change the policy template parameters before you initiate the policy construction phase. See the "Understanding Policy Templates" section on page 7-4 for more information.

The Guard sets default values for the policy parameters (timeout, action and threshold). See Chapter 7, "Configuring Policy Templates and Policies," for information on how to configure the default values for the operational parameters.

The new policies that the Guard creates in this phase replace the existing ones.


Note You cannot perform the policy construction phase of the learning process for zones that are based on these bandwidth-limited link zone templates: GUARD_LINK_128K, GUARD_LINK_1M, GUARD_LINK_4M, and GUARD_LINK_512K.


To construct the zone policies, perform the following steps:


Step 1 Initiate the policy construction phase by entering the following command in zone configuration mode:

learning policy-construction


Tip Check that the Guard is diverting the zone traffic. Wait at least 10 seconds after initiating policy construction or threshold tuning and enter the show rates details command. Verify that the value of the Received traffic rate is greater than zero. A value of zero indicates a diversion problem.


Step 2 (Optional) Display the policies that the Guard is constructing.

You can save a snapshot of the learning parameters (services, thresholds, and other policy related data) by using the snapshot command at any stage during the policy construction phase, and review it later. You can save a single snapshot or save a periodic snapshot at specified intervals.

For more information, see the "Using Snapshots to Verify the Results of the Learning Process" section on page 7-35.

Step 3 (Optional) If you run the policy construction phase for a long period of time you can accept the policies that the Guard suggested without stopping the policy construction phase. You can accept the policies once, or define that the Guard automatically accept the suggested policies at specified intervals. You can ensure that the zone has the most updated policies and continues to learn the zone traffic.

To accept the policies that the Guard suggested and continue the policy construction phase, enter the following command:

learning accept

To automatically accept the policies that the Guard suggests at specified intervals, enter the following command:

learning-params periodic-action auto-accept learn_params_days 
learn_params_hours learn_params_minutes

See the "Configuring Learning Parameters" section for more information.

Use the no learning-params periodic-action command to terminate the periodic action.

Step 4 After a sufficient period of time, terminate the policy construction phase and decide how to handle the newly constructed policies.

We recommend letting the policy construction phase continue for at least 2 hours before terminating it.

You can perform one of the following actions:

Accept the suggested policies—You can accept the policies that the Guard suggested by entering the following command in zone configuration mode:

no learning accept

The Guard erases previously learned policies and thresholds.

After accepting the newly constructed policies, you can manually add or remove policies. See Chapter 7, "Configuring Policy Templates and Policies." for more information.

Reject the suggested policies—You can reject the policies that the Guard suggested by entering the following command in zone configuration mode:

no learning reject

The Guard stops the process and does not save the new policies that it has just learned. The policies of the zone are the policies that the Guard had prior to initiating the learning process or prior to the last time that you accepted the results of the policy construction phase.


The following example shows how to initiate the policy construction phase and accept the suggested policies at 12 hour intervals. It then stops the policy construction phase and accepts the suggested policies.

user@GUARD-conf-zone-scannet# learning policy-construction
user@GUARD-conf-zone-scannet# learning-params periodic-action 
auto-accept 0 12 0
user@GUARD-conf-zone-scannet# no learning accept

Tuning Thresholds

In the threshold tuning phase, the Guard analyzes the zone traffic and defines thresholds for the policies that were constructed during the policy construction phase.

You can set the Guard to learn the zone traffic while monitoring the last accepted policy thresholds for traffic anomalies. After the Guard detects an attack on the zone, it stops the threshold tuning phase but continues zone protection to prevent the Guard from learning malicious traffic thresholds.

The Guard resumes the learning process after the attack ends. The Guard waits for a period of time, as defined by the protection-end-timer but no longer than 10 minutes, after the attack has ended before reactivating the learning process. See the"Configuring the Protection Inactivity Timeout" section for more information.

To tune the policy thresholds, perform the following steps:


Step 1 Initiate the threshold tuning phase by entering the following command in zone configuration mode:

protect learning

We recommend that you enable the protect and learn function, that is, activate the threshold tuning phase and set the Guard to perform zone protection at the same time.

You can alternatively, enter both the learning threshold-tuning command and the protect command (the order is not important).


Tip Check the Guard is diverting the zone traffic. Wait at least 10 seconds after initiating the policy construction phase or threshold tuning phase and enter the show rates details command. Verify that the value of the Received traffic rate is greater than zero. A value of zero indicates a diversion problem.


If the Guard detects an attack on the zone, it stops the threshold tuning phase but continues zone protection.


Note If you activate the protect and learn function when traffic to the zone is moderate, the Guard may regard the traffic during peak time as an attack. In this case, you can perform one of the following tasks:

Set the state of the zone policy thresholds to untuned by entering the no learning-params threshold-tuned command in zone configuration mode. See the "Marking the Policies as Tuned" section for more information.

Deactivate zone protection and continue to learn the zone policy thresholds by entering the no protect command in zone configuration mode.


To deactivate zone protection and the threshold tuning phase simultaneously, enter the deactivate command in zone configuration mode.

To activate the threshold tuning phase only, use the learning threshold-tuning command.

Step 2 (Optional) Display the zone policies that the Guard is tuning.

You can save a snapshot of the learning parameters (services, thresholds, and other policy-related data) by using the snapshot command at any time during the threshold tuning phase. You can review the snapshot later or compare the learning parameters with another snapshot. You can save a single snapshot or save a periodic snapshot at specified intervals.

For more information, see the "Using Snapshots to Verify the Results of the Learning Process" section on page 7-35.

Step 3 Accept the policies.

You can accept the zone policies that the Guard suggested and continue the threshold tuning phase once, or define that the Guard automatically accept the suggested policies at specified intervals to ensure that the zone has the most updated policies and continues to learn the zone traffic.

To accept the policies that the Guard suggested and continue the threshold tuning phase, enter the following command:

learning accept [threshold-selection {new-thresholds | max-thresholds 
| weighted weight}]

See Table 5-7 for a description of the threshold-selection arguments and keywords.

To automatically accept the policies that the Guard suggests at specified intervals, enter the following command:

learning-params periodic-action auto-accept learn_params_days 
learn_params_hours learn_params_minutes

See the "Configuring Learning Parameters" section for more information.

Use the no learning-params periodic-action command to terminate the periodic action.

Step 4 After a sufficient period of time, you can terminate the threshold tuning phase and decide how to handle the newly tuned policies.


Note We recommend that you run the threshold tuning phase during peak traffic time (the busiest part of the day) for a minimum of 24 hours.


However, if the Guard is constantly diverting the zone traffic, we recommend that you keep the protect and learn function active and do not terminate the threshold tuning phase.

You can perform one of the following actions:

Accept the suggested policies—You can accept the policy thresholds that the Guard suggested by entering the following command in zone configuration mode:

no learning accept [threshold-selection {new-thresholds | 
max-thresholds | weighted weight}]

See Table 5-7 for a description of the threshold-selection arguments and keywords.

The Guard erases previously learned thresholds.

After accepting the newly tuned policies, you can manually change the policy parameters. See Chapter 7, "Configuring Policy Templates and Policies," for more information.

Reject the suggested policies—You can reject the policy thresholds that the Guard suggested by entering the following command in zone configuration mode:

no learning reject

The Guard stops tuning the thresholds and reverts to prior thresholds. This process may result in a situation in which new zone policies have thresholds that were obtained according to past traffic characteristics. We recommend that you enable the threshold tuning phase at a later time or that you configure the thresholds manually.


The following example shows how to initiate the threshold tuning phase and accept the suggested policies at 1 hour intervals. It then stops the threshold tuning phase and accepts the suggested policies if the threshold values are higher than the current values (the max-thresholds method).

user@GUARD-conf-zone-scannet# learning threshold-tuning
user@GUARD-conf-zone-scannet# learning-params periodic-action 
auto-accept 0 1 0
user@GUARD-conf-zone-scannet# no learning accept threshold-selection 
max-thresholds

To display the learning results, use the show policies statistics command. See the "Displaying Policies" section on page 7-31 for more information.

After reviewing the learned thresholds, you may choose to modify some of the results. To avoid overriding these changes by future threshold tuning phases, perform one of the following tasks:

Set the policy threshold as fixed—The Guard ignores new thresholds and maintains the current ones. See the "Setting the Threshold as Fixed" section on page 7-22 for more information.

Set a fixed multiplier for the policy—The Guard calculates new policy thresholds by multiplying the learned threshold by the specified multiplier and then applying the threshold selection method on the result. See the "Configuring a Threshold Multiplier" section on page 7-23 for more information.

Configuring Learning Parameters

The learning parameters allow you to configure the learning-related actions that the Guard can perform and how the Guard handles specified policies. You can define the following parameters:

periodic-action—You can set the Guard to automatically accept the zone policies and save a snapshot of the zone policies, or you can set the Guard to save a snapshot of the zone policies only at specified intervals. See the "Configuring Periodic Actions" section for more information.

threshold-tuned—You can mark the zone policies as tuned. If the zone policies are not marked as tuned, the Guard does not detect attacks on the zone. See the "Marking the Policies as Tuned" section for more information.

threshold-selection—You can set the default method that the Guard uses to generate new policy thresholds after it accepts the results of the threshold tuning phase. See the "Configuring the Threshold Selection Method" section for more information.

fixed-threshold—You can set the policy threshold as fixed. The Guard does not change the value of the policy threshold in future threshold tuning phases. See the "Setting the Threshold as Fixed" section on page 7-22 for more information.

threshold-multiplier—You can set a fixed multiplier for the policy threshold. The Guard calculates the policy threshold in future threshold tuning phases based on the current policy threshold, the learned threshold, and the fixed multiplier. See the "Configuring a Threshold Multiplier" section on page 7-23 for more information.

To display the configuration of the learning parameters, use the show learning-params command in zone configuration mode.

Configuring Periodic Actions

You can set the Guard to perform one of the following actions at specified intervals:

Automatically accept the zone policies and save a snapshot of the policies

Save a snapshot of the zone policies only

See the "Monitoring Policies" section on page 7-31 for more information on snapshots.

To set the periodic action the Guard performs, enter the following command in zone configuration mode:

learning-params periodic-action {auto-accept | snapshot-only} learn_params_days learn_params_hours learn_params_minutes

Table 5-6 provides the arguments and keywords for the learning-params command.

Table 5-6 Arguments and Keywords for the learning-params periodic-action Command 

Parameter
Description

auto-accept

Accepts the policies that the Guard suggests at the specified interval. The Guard saves a snapshot of the zone policies after accepting the newly suggested ones.

snapshot-only

Saves a snapshot of the policies at the specified interval. The Guard does not accept the new policies and does not modify the policy thresholds.

learn_params_days

The interval in days. Enter an integer from 0 to 1000.

learn_params_hours

The interval in hours. Enter an integer from 0 to 1000.

learn_params_minutes

The interval in minutes. Enter an integer from 0 to 1000.


The value of the interval is the sum of the learn_params_days value, the learn_params_hours value, and the learn_params_minutes value.

The following example shows how set the Guard to accept the policies at 1 hour intervals.

user@GUARD-conf-zone-scannet# learning-params periodic-action 
auto-accept 0 1 0

Configuring the Threshold Selection Method

You can set the default method that the Guard uses to generate new thresholds after new policy thresholds are accepted during the threshold tuning phase. You can accept the results of the threshold tuning phase manually, or configure the Guard to automatically accept the results of the threshold tuning phase at specified intervals.

To configure the threshold selection method, enter the following command in zone configuration mode:

learning-params threshold-selection {new-thresholds | max-thresholds | weighted weight}

Table 5-7 provides the arguments and keywords for the learning-params threshold-selection command.

Table 5-7 Arguments and Keywords for the learning-params threshold-selection Command 

Parameter
Description

new-thresholds

Saves the results of the leaning process to the zone configuration.

max-thresholds

Compares the current policy threshold to the learned threshold and saves the higher of the two to the zone configuration.

This method is the default.

weighted weight

Calculates the policy thresholds to save based on the following formula:

new-threshold = ((learned-threshold * weight + current-threshold * (100 - weight)) / 100


This example shows how to configure the Guard to accept the suggested policies if the learned threshold values are higher than the current policy threshold values:

user@GUARD-conf-zone-scannet# learning-params threshold-selection 
max-thresholds

Marking the Policies as Tuned

The Guard marks the policy threshold status that defines if the policy thresholds are tuned or not, and relates to this status when you enable the protect and learn function. The policy threshold status specifies if the Guard identifies an attack on the zone when the policy threshold is exceeded.

When a new zone is created, or after you accept the policy construction phase results for a zone, the Guard marks the zone policy thresholds as untuned. The default thresholds of the zone templates are tuned so that the Guard activates the anti-spoofing functions quickly if it identifies traffic anomalies in the zone traffic. When you enable the protect and learn function, the learning process might stop if the current zone traffic is higher than the current policy threshold values. To avoid such situations, the Guard does not detect attacks in the zone traffic when you enable the protect and learn function if the zone policies are not tuned, until the zone policy thresholds are accepted one time.

If the zone policies are untuned, the Guard activates only a threshold selection method of accept-new and ignores previous threshold values when accepting the new policies. If the Guard accepts the threshold tuning phase results of the learning process for a zone with a threshold selection method other than accept-new, bad policy threshold values may result. See the "Configuring the Threshold Selection Method" section for more information on the threshold selection method.

The Guard marks the zone policies as untuned in the following circumstances:

When creating a new zone

After accepting the policy construction phase results

After removing a service or adding a new service to the zone policies

The Guard marks the zone policies as tuned after accepting the threshold tuning phase results.

You can modify the settings of the zone policies. To mark the zone policies as tuned, enter the following command in zone configuration mode:

learning-params threshold-tuned

To mark the zone policies as untuned, use the no form of this command.

You might change the status of the zone policies to tuned when one of the following applies:

The new zone is duplicated from an existing zone or snapshot that has similar traffic characteristics.

You have manually configured all policy thresholds.

You might change the status of the zone policies to untuned when one of the following applies:

A major change was made in the zone network.

The zone IP address or subnet was modified.

You have not initiated the protect and learn function during peak traffic time (to prevent the Guard from regarding the traffic during peak time as an attack).

When the zone policies are marked as untuned, the Guard does not monitor the current policy thresholds and does not detect attacks on the zone if the policy thresholds are exceeded.


Note Do not change the status of the zone policies to untuned if there is attack on the zone because that prevents the Guard from detecting the attack and causes the Guard to learn thresholds of malicious traffic.


The following example shows how to mark the status of the zone policies as tuned:

user@GUARD-conf-zone-scannet# learning-params threshold-tuned

Tuning Zone Policy Thresholds and Enabling Zone Protection Simultaneously

After an initial learning process of constructing policies, you can activate the learning process and enable zone protection simultaneously using the protect and learn function. The Guard tunes the policy thresholds and at the same time monitors the policy thresholds for traffic anomalies. The protect and learn function enables the Guard to protect the zone, constantly update the policy thresholds according to the zone traffic characteristics, and prevents the Guard from learning malicious traffic thresholds.

When you create a new zone, when you add or remove a service from the zone policies, or after you accept the policy construction phase results, the Guard marks the zone policies as untuned. The Guard marks the zone policies as tuned only after you accept the results of the threshold tuning phase of the learning process.

If you enable the learning process and zone protection simultaneously and the zone policies are not tuned, the Guard functions in the following ways:

The Guard does not detect attacks in zone traffic (until the zone policy thresholds are accepted once)

The Guard activates a threshold selection method of accept-new only (see the "Configuring the Threshold Selection Method" section)

When the Guard identifies an attack on the zone, it stops the learning process but continues to protect the zone and resumes protecting the zone and learning the zone traffic characteristics when the attack ends.

Before you activate the protect and learn function, you can configure when and how the Guard accepts the results of the learning process. See the "Configuring Learning Parameters" section for more information.

To activate the learning process and zone protection simultaneously, use the protect learning command or enter both the learning threshold-tuning command and the protect command (the order is not important).

See the "Tuning Thresholds" section and the "Protecting the Zone" section for more information.

Synchronizing the Zone Configuration in the Guard with the Cisco Traffic Anomaly Detector

You can synchronize the zone configuration and policies with the zone on the Cisco Traffic Anomaly Detector (Detector). The Detector copies the complete zone configuration to the Guard. This process allows you to configure the zone once, but maintain the same configuration and policies on both the Guard and the Detector.

Communication between the Detector and the Guard requires the Secure Sockets Layer (SSL) protocol, which provides authentication and encryption. You must configure the SSL communication connection channel before you synchronize the zone. See the "Establishing Communication with the Cisco Traffic Anomaly Detector" section on page 3-22 for more information.

You can set the Detector to continuously learn the zone traffic characteristics to keep the zone policies updated, and avoid constantly diverting the zone traffic to the Guard.

You must create the zone for synchronization and synchronize the zone from the Detector. See the Cisco Traffic Anomaly Detector Configuration Guide for more information.

This section contains the following topics:

Configuration Guidelines

Synchronizing the Zone Configuration Offline

Example Scenario

Configuration Guidelines

To synchronize zones between a Guard and a Detector, use the following guidelines:

Create the new zone on the Detector using zone templates that are appropriate for both the Guard and the Detector (GUARD zone templates).

Ensure that the same type of traffic flows to both the Guard, when it is diverting traffic, and the Detector for proper synchronization of zone policies. Otherwise, the zone global policies may be too high or too low to guarantee proper protection for spoofed DDoS attacks.

Use the Detector as the central configuration point because you can create new zones on the Detector only and the configuration file of the Detector contains the configuration of both the Detector zones and the Guard zones. Configure the zones on the Detector and maintain a backup of the Detector configuration. Copy the zone configuration from the Detector to the Guard.

If you change (swap out) a device or the IP address of the interface that the Detector and the Guard use to communicate, regenerate the SSL certificates that the Detector and the Guard use for secure communication.

Verify the zone configuration on the Guard. If the activation extent is ip-address-only and the activation method is not zone-name-only, we recommend that you configure the timer that the Guard uses to identify that an attack on the zone has ended by entering the protection-end-timer command. If the value of the protection-end-timer is forever, the Guard does not identify that an attack on the zone has ended and does not delete the sub-zone it had created to protect the specific IP address.

See the "Configuring the Activation Method" section, the "Configuring the Activation Extent" section, and the "Configuring the Protection Inactivity Timeout" section for more information.

Synchronizing the Zone Configuration Offline

You can synchronize a zone configuration even if you cannot establish a secure communication channel between the Detector and a Guard. You may need to synchronize a zone configuration offline if one of the following conditions applies:

The is Guard does not have access to the Detector

The is Detector does not have access to the Guard

The Detector communicates with the Guard across a Network Address Translation (NAT) device

To synchronize a zone configuration offline, you must first export the zone configuration from the Detector to an FTP or a Secure FTP (SFTP) server, and then manually import the zone configuration to the Guard. Because there is no secure communication channel between the Guard and the Detector, you must manually activate the Guard to protect the zone when the Detector detects anomalies in the zone traffic.

See the "Protecting the Zone" section for more information.

To enable the Guard to synchronize the zone configuration, you must create the zone on the Detector using one of the GUARD zone templates.

To synchronize the zone configuration offline, perform the following steps:


Step 1 Export the zone configuration from the source device (Guard or Detector) by entering the following command in global mode:

copy zone zone-name running-config ftp 

See the "Exporting Configuration" section on page 11-2.

Step 2 Import the zone configuration from an FTP or SFTP server to the target device by entering one of the following commands in global mode:

copy ftp running-config server full-file-name [login [password]]

copy sftp running-config server full-file-name login

See the "Importing and Updating Configuration" section on page 11-3 for more information.



Note We recommend that you deactivate a zone before importing the zone configuration.


Example Scenario

This example scenario shows how to make use of synchronization to ensure proper zone protection according to current traffic characteristics:

1. Create and configure a new zone on the Detector using one of the GUARD zone templates.

The Guard identifies such zones by displaying (Guard/Detector) next to the zone ID field in the output of the show command in zone configuration mode.

2. Add the Guard to the zone SSL remote Guard list or the default SSL remote Guard list on the Detector.

3. Set the Detector to construct the zone policies by entering the learning policy-construction command.

4. Set the Detector to learn the zone traffic and tune the policy thresholds while detecting traffic anomalies by entering the detect learning command.

5. Configure the Detector to accept the policy thresholds every 24 hours to ensure that the zone policies are updated with the changing traffic patterns.

6. Configure the Detector to synchronize the zone configuration with the Guard each time that it accepts the new learned policy thresholds to ensure that when the Detector learns new zone policy thresholds, the zone policies on the Guard are also updated.

7. Configure the Detector to synchronize the zone configuration with the configuration on the Guard before activating the Guard to protect the zone to ensure that the zone configuration and policies on the Guard are updated when the Guard activates zone protection.

8. When the Detector detects an attack on the zone, it performs the following actions:

Verifies that the zone configuration on the Guard is updated. If the zone configuration on the Guard is not the same as the zone configuration on theDetector, the Detector synchronizes the zone configuration.

Activates the Guard to protect the zone (The Guard activates zone protection).

Stops the learning process for the zone but continues to detect anomalies in the zone traffic to prevent the Detector from learning malicious traffic thresholds.

You can modify the zone policies on the Guard when the attack is in progress.

The Detector polls the Guard constantly and when it identifies that the Guard has deactivated zone protection (the Guard deactivates zone protection when the attack ends) and additional traffic anomalies do not exist and then reactivates zone anomaly detection and the learning process.

9. If you manually modify the zone policies on the Guard to adjust the zone policies to the attack characteristics, you can synchronize the new policies with the Detector. This is important if the zone traffic requires that you set certain policy thresholds as fixed or set a fixed multiplier for policy thresholds because it ensures that the Detector has the correct policy thresholds, calculates the thresholds correctly in future threshold tuning phases, and updates the Guard policies with the correct thresholds.

For more information, see the "Setting the Threshold as Fixed" section on page 7-22 and the "Configuring a Threshold Multiplier" section on page 7-23.

You can perform this action only from the Detector. See the Cisco Traffic Anomaly Detector Configuration Guide for more information.

Protecting the Zone

Before activating zone protection, we recommend that you let the Guard study the zone traffic patterns or synchronize the zone configuration, including the zone policies, from a Cisco Traffic Anomaly Detector (Detector). The learning process allows the Guard to learn the traffic patterns of each zone and to create sets of recommended thresholds according to statistical analysis of the zone traffic. You can protect several zones at the same time only if their IP address ranges do not overlap.

You must configure diversion before initiating the learning process or divert the zone traffic to the Guard manually. Configure zone diversion using the Guard routing configuration.

See Chapter 4, "Configuring Traffic Diversion" for more information.

If the zone is not under attack, you can activate the protect and learn function to enable the Guard to constantly divert the zone traffic and tune the zone policy thresholds. See the "Learning the Zone Traffic Characteristics" section for more information.

You can define the following protection characteristics:

Operation mode—You can configure how the Guard performs zone protection and define whether the Guard applies measures to protect the zone automatically or in an interactive manner.

Activation method—You can define whether to activate the zone according to the zone name, the zone address range or the received traffic. You should configure the activation method if zone protection is activated by an external device (such as a Cisco Traffic Anomaly Detector).

Activation extent—You can define whether to activate zone protection for the entire zone address range, or only for a specific IP address within the zone. The activation extent applies to zones where zone protection is activated by an external device, such as a Cisco Traffic Anomaly Detector, only.

Protection termination timeout—You can define the timeout after which the Guard terminates zone protection.

This section contains the following topics:

Activating Zone Protection

Deactivating Zone Protection

Configuring How the Guard Performs Zone Protection

Configuring the Activation Method

Configuring the Activation Extent

Configuring the Protection Inactivity Timeout

Activating Zone Protection

You can wait for an external device (such as a Cisco Traffic Anomaly Detector) to detect an attack on the zone before setting the Guard to protect the zone, or command the Guard to protect the zone after configuring the zone. When the Guard protects a zone, the Guard diverts the zone traffic to itself and applies its protection policies.

If the zone is under attack before the Guard has learned the zone traffic characteristics, use on-demand protection to protect the zone. The Guard default policy thresholds for a new zone enable effective on-demand protection. See the "Enabling On-Demand Protection" section for more information.


Note You must manually divert the zone traffic to the Guard using an external device if you configure the activation extent by entering the activation-interface command to packet or the Guard cannot monitor the zone traffic.


You can activate zone protection in one of the following ways:

You can protect the entire zone—See the "Protecting the Entire Zone" section)

You can protect an IP-specific zone that is a part of the zone address range—"Protecting an IP Zone that is Part of the Zone Address Range" section

You can protect a specific IP address even if you do not know the name of the zone that the IP address is in the range of—"Protecting an IP Address when the Zone Name is Not Known" section


Tip Check that the Guard is receiving the zone traffic. Wait at least 10 seconds after activating zone protection and enter the show rates command. Verify that the value of at least one of the rates is greater than zero. If the value of all rates equals zero, a diversion problem could exist.


Protecting the Entire Zone

You can protect the entire zone by entering the following command in zone configuration mode:

protect [learning]

The learning keyword sets the Guard to protect the zone and tune the policy thresholds. See the "Tuning Thresholds" section for more information.

The following example shows how to activate zone protection:

user@GUARD-conf-zone-scannet# protect

Protecting an IP Zone that is Part of the Zone Address Range

You can protect an IP-specific zone that is a part of the zone address range. In this case, the Guard creates a new zone. The name of the new zone consists of the first 30 characters of the major zone and the specific IP address concatenated by an underscore. If a zone by the same name already exists, the Guard activates zone protection for the existing zone instead of creating another zone by the same name.

To activate zone protection for an IP-specific zone, enter the following command in global mode:

protect zone-name ip-address-general

Table 5-8 provides the arguments for the zone configuration mode protect command.

Table 5-8 Arguments for the Zone Configuration Mode protect Command 

Parameter
Description

zone-name

The name of the zone

ip-address-general

The specific IP address within the zone address range. Enter the IP address in dotted-decimal notation. For example, enter 192.168.5.6.


To remove this zone, use the no form of the zone command.

The following example shows how to activate zone protection for IP address 192.168.5.6 that is included in the IP address range of the zone scannet:

user@GUARD# protect scannet 192.168.5.6
creating zone scannet_192.168.5.6
user@GUARD#

Protecting an IP Address when the Zone Name is Not Known

You can protect a specific IP address even if you do not know the name of the zone that the IP address is its IP address range by entering the following command in global mode:

protect ip-address-general [subnet-mask]

Table 5-9 provides the arguments for the global mode protect command.

Table 5-9 Arguments for the Global Mode protect Command 

Parameter
Description

ip-address-general

The specific IP address within a zone address range. Enter the IP address in dotted-decimal notation. For example, enter 192.168.5.6.

subnet-mask

The subnet mask for which zone protection is activated. Enter the IP address in dotted-decimal notation. For example, enter 255.255.255.252.


The Guard activates zone protection according to the IP address activation method. See the "Configuring the Activation Extent" section for more information.

The following example shows how to activate zone protection for IP address 192.168.5.6:

user@GUARD# protect 192.168.5.6

You can enter the protect-related commands for several zones at the same time. Enter the command in global mode and use an asterisk (*) as a wildcard. For example, to stop zone protection for all zones, enter the no protect * command in global mode. To stop zone protection for all zones with names that begin with scan (such as scannet and scanserver), enter the no protect scan* command in global mode.

Deactivating Zone Protection

When there is no attack on a zone and you rely on another source for detecting zone traffic anomalies, you may want to deactivate zone protection and end traffic diversion to the Guard.

To deactivate zone protection, enter one of the following commands in zone configuration mode:

no protect—Ends zone protection. If you enabled the protect and learn function, the Guard continues to learn the policy thresholds.

deactivate—Ends both zone protection and the threshold tuning phase of the learning process.

The following example show how to deactivate zone protection and the learning process:

user@GUARD-conf-zone-scannet# deactivate

Configuring How the Guard Performs Zone Protection

You can configure the Guard to perform zone protection in one of the following ways:

Automatic protect mode—Dynamic filters are activated without user intervention. This operation mode is the default.

Interactive protect mode—Dynamic filters are activated manually in an interactive mode. The dynamic filters are grouped as recommendations that await your decision. You can review and decide which recommendations to accept, ignore, or direct to automatic activation.

See Chapter 8, "Using Interactive Protect Mode," for more information.

Configuring the Activation Method

The activation method defines how the Guard identifies the zone for which it activates zone protection once it receives an external indication. This indication can be a command from an external device, such as a Cisco Traffic Anomaly Detector, or traffic that is destined to the zone (packet).

The Guard supports the following activation methods:

Zone name—Activates zone protection based on the zone name. A command from an external device, such as a Cisco Traffic Anomaly Detector, to activate zone protection must include the zone name. This activation method is the default.

IP address—Activates zone protection when it receives a command from an external device, such as a Cisco Traffic Anomaly Detector, that consists of an IP address or subnet that is part of the zone. The Guard scans the zone database and activates the zone that has an address range that includes the received IP address or subnet. If you have configured several zones with an address range that includes the receive IP address, the Guard activates the zone with the longest prefix match (the zone which that has the most specific address range that includes the receive IP address). The received IP address or subnet must be completely included in the zone IP address range.


Caution Do not configure more than one zone with the same address range with an address or packet activation method.

Packet (Traffic)—Activates zone protection when it receives traffic that is destined to the zone. The Guard scans the zone database and activates the zone that has an address range that includes the received packet IP address. If you have configured several zones with an address range that includes the received packet IP address, the Guard activates the zone with the longest prefix match (the zone that has the most specific address range that includes the received packet IP address). The received IP address or subnet must be completely included in the zone IP address range.

The Guard activates zone protection only if the received traffic rate to a single IP address is higher than the activation sensitivity. The activation sensitivity is defined globally and applies to all zones.

To change the minimum packet rate that is required to activate zone protection, enter the following command in configuration mode:

protect-packet activation-sensitivity min-rate

The min-rate argument defines the minimum packet rate that is destined to a single zone destination IP address that causes the Guard to activate zone protection. The default is 0 pps.


Note You must manually divert the zone traffic to the Guard using an external device if you configure the activation extent by entering the activation-interface command to packet or the Guard cannot monitor the zone traffic.


IP Address or Packet—Activates zone protection when it receives traffic (packet) that is destined to the zone or when it receives a command from an external device, such as the Cisco Traffic Anomaly Detector, that consists of an IP address or subnet that is part of the zone address range. See the bullets IP address and Packet (Traffic) bullets in this section for more information.

If the activation method is not zone-name-only, the Guard activates the entire zone or the specified IP address range according to the zone activation extent (see "Configuring the Activation Extent" section).

To configure the activation method, enter the following command in zone configuration mode:

activation-interface {packet | ip-address | packet-or-ip-address | zone-name-only}

The default is zone-name-only. If you duplicate a zone (see the "Duplicating a Zone" section), the activation interface is set to the default, regardless of the configuration of the source zone.


Note If the activation extent is ip-address-only (see "Configuring the Activation Extent" section) and the activation method is not zone-name-only, we recommend that you configure the timer that the Guard uses to identify that an attack on the zone has ended by using the protection-end-timer command (see the "Configuring the Protection Inactivity Timeout" section). If the value of the protection-end-timer is forever, the Guard does not identify that an attack on the zone has ended and does not delete the sub-zone that it has created to protect the specific IP address.


You can create a default zone for the Guard to protect if the received IP address or packet is not part of any other zone. You can define a default zone only if the network is homogenous and can use the same zone template. You cannot perform the learning process for a default zone. Create the zone with an IP address of 0.0.0.0 and a subnet of 0.0.0.0. Define the activation extent as ip-address (see the "Configuring the Activation Extent" section).

To display the zone activation method, enter the show running-config command in zone configuration mode.

Configuring the Activation Extent

The activation extent defines whether to activate zone protection for the entire zone or for a partial zone once the Guard receives an external indication. This indication can be a command from an external device, such as the Cisco Traffic Anomaly Detector, or traffic that is destined to the zone (packet).

The Guard supports the following activation extents:

Entire zone—Activates zone protection for the entire zone. The Guard activates zone protection when it receives traffic that is destined to the zone or when it receives an external indication that consists of an IP address or subnet that is part of the zone.

IP Address only—Activates zone protection only for the specified IP address or subnet. When the Guard receives traffic that is destined to the zone or when it receives a command from an external device, such as the Cisco Traffic Anomaly Detector, that consists of an IP address or subnet that is part of the zone, the Guard creates a new zone (subzone). This activation extent is the default. See the "Understanding Subzones" section for more information.

To configure the activation extent, enter the following command in zone configuration mode:

activation-extent {entire-zone | ip-address-only}

Table 5-9 provides the arguments for the activation-extent command.

Table 5-10 Arguments for the activation-extent Command 

Parameter
Description

entire-zone

Activates zone protection for the entire zone.

ip-address-only

Activates zone protection only for the specified IP address or subnet. This activation extent is the default.


The following example shows how to configure the activation extent to entire-zone:

user@GUARD-conf-zone-scannet# activation-extent entire-zone

To display the zone activation extent, use the show running-config command.

Understanding Subzones

The Guard creates a subzone when it activates zone protection for a partial zone (a zone that does not include the complete IP address range of the source zone). The IP address range of the subzone is included in the address range of the source zone.

The subzone configuration is identical to the configuration of the source zone apart from the IP address and name that are different. The name of the subzone consists of the first 30 characters of the name of the source zone, the IP address and the subnet, concatenated with underscores. If the subzone consists of a single IP address, the subnet is not added. For example, If the name of the source zone is scannet with an address range of 10.10.10.0 and a subnet of 255.255.255.0 and the Guard activates zone protection for an internal range of IP address 10.10.10.192 and subnet 255.255.255.252, the name of the subzone is scannet_10.10.10.192_255.255.255.252.

The IP address and subnet of the subzone are the IP address and subnet that the Guard received with the external command, or the IP address of the packet that triggered the Guard to activate zone protection.

Once zone protection for the subzone ends, the Guard erases the subzone, but does not erase the logs and attack reports of the subzone.The Guard terminates zone protection for a subzone according to the activation method and the protection termination timeout that are configured for the source zone.

To display the logs and reports of the subzone after the Guard has erased it, enter the following commands:

show log sub-zone-name—See the "Displaying the Guard Configuration" section on page 10-2 for more information

show reports sub-zone-name [report-id | current] [details]—See the "Displaying Attack Reports" section on page 9-12 for more information

To display a list of the subzones, enter the command and press TAB for the sub-zone-name argument.

Configuring the Protection Inactivity Timeout

The Guard can activate or deactivate zone protection and the learning process when the Guard identifies that an attack on the zone has ended. If the Guard is protecting a zone, it terminates zone protection when the zone is no longer under attack. If the protect and learn function is enabled, the Guard deactivates the learning process when it detects an attack on the zone, and resumes the learning process when the zone is no longer under attack.

The Guard verifies whether an attack on the zone has ended according to an inactivity timeout. You can define this timeout from seconds to infinite.

To define the inactivity timeout, enter the following command in zone configuration mode:

protection-end-timer {time-seconds | forever}

Table 5-11 provides the arguments and keywords for the protection-end-timer command.

Table 5-11 Arguments and Keywords for the protection-end-timer Command

Parameter
Description
time-seconds

The timeout in seconds. Enter an integer greater than 60.

forever

Indefinite timeout.


The default is forever. If you do not change the default value, you must deactivate zone protection manually.

The following example shows how to configure the protection inactivity timeout:

user@GUARD-conf-zone-scannet# protection-end-timer 300

The Guard measures the inactivity based on dynamic filter inactivity and dropped traffic. If for a predefined span of time, no Dynamic filters are in use and both the following conditions apply, the Guard assumes the attack on the zone has ended:

No new dynamic filters are added—See the "Deactivating Dynamic Filters" section on page 6-34 for information on how the Guard decides when to remove dynamic filters.

The rate of the zone traffic that is being dropped is lower than the defined threshold—The Guard drops zone packets that the dynamic filters, user filters, and flex-content filters have identified as part of an attack, or traffic that has exceeded the rate limit that was defined for the zone using the rate-limit command. It counts the dropped packets using the zone dropped counter (see the "Displaying Zone Counters" section on page 10-4 for more information). The default threshold is 1 pps. To change the drop counter threshold, enter the following command in zone configuration mode:

attack-detection zone-malicious-rate threshold

The threshold argument defines the minimum rate of dropped zone packets. If the rate goes lower than this threshold, the Guard may end zone protection.

If the zone activation method is Packet, the Guard checks for inactivity based on the received traffic before deactivating a zone. The Guard deactivates protection only if the previous conditions apply, and no packet to the zone was received.

Enabling On-Demand Protection

You can protect a zone without performing the learning process in an immediate need such as a zone under attack. The system-defined zone templates include predefined zone protection policies and user filters that are suited to protect a zone that has not finished the learning process. The default thresholds of these zone policies are tuned so that the Guard activates the anti-spoofing functions quickly if it identifies traffic anomalies in the zone traffic.

Because the Guard does not know the zone traffic patterns, the thresholds used to block (drop) source IP addresses are set to high values. On-demand protection requires user intervention when mitigating non-spoofed attacks. You must monitor the zone legitimate and malicious traffic rates and view the Guard mitigation actions.

You may require on-demand protection for a zone if there is an attack on the zone and one of the following conditions apply:

The zone is in the learning process.

You have enabled the protect and learn function but the Guard has not yet learned the zone traffic characteristics.

You have accepted policy thresholds that you think do not represent the zone traffic.

To initiate on-demand protection, perform the following steps:


Step 1 Create a new zone by entering the following command:

zone new-zone-name [template-name] [interactive]

See the "Creating a New Zone" section for more information.

Step 2 Define the zone IP address by entering the following command:

ip address ip-addr [ip-mask] 

See the "Configuring Zone Attributes" section for more information.

Step 3 Activate zone protection by entering the following command:

protect

See the "Protecting the Zone" section for more information.

Step 4 Analyze the zone traffic patterns. See Chapter 12, "Analyzing Guard Mitigation" for more information.


a