Handling False Alarms

If you confirm that an attack event on the Events page is a false alarm, you can handle the event as false alarm by ignoring the URL and rule ID in basic web protection, or by deleting or disabling the corresponding protection rule you configured. After an attack event is handled as a false alarm, the event will not be displayed on the Events page anymore. You will no longer receive any alarm notifications about the event.

WAF detects attacks by using built-in basic web protection rules, built-in features in anti-crawler protection, and custom rules you configured (such as CC attack protection, precise access protection, blacklist, whitelist, and geolocation access control rules). WAF will respond to detected attacks based on the protective actions (such as Block and Log only) defined in the rules and display attack events on the Events page.

If you have enabled enterprise projects, you can select your enterprise project from the Enterprise Project drop-down list and handle false alarms in the project.

Prerequisites

There is at least one false alarm event in the event list.

Constraints

  • Only attack events blocked or recorded by preconfigured basic web protection rules and features in anti-crawler protection can be handled as false alarms.
  • For events generated based on custom rules (such as a CC attack protection rule, precise protection rule, blacklist rule, whitelist rule, or geolocation access control rule), they cannot be handled as false alarms. To ignore such an event, delete or disable the custom rule hit by the event.
  • An attack event can only be handled as a false alarm once.

Application Scenarios

Sometimes normal service requests may be blocked by WAF. For example, suppose you deploy a web application on a HUAWEI CLOUD ECS and then add the public domain name associated with that application to WAF. If you enable basic web protection for that application, WAF may block the access requests that match the basic web protection rules. As a result, the website cannot be accessed through its domain name. However, the website can still be accessed through the IP address. In this case, you can handle the false alarms to allow normal access requests to the application.

Impact on the System

The attack event will not be displayed on the Events page. You will no longer receive any alarm notifications about the event.

Procedure

  1. Log in to the management console.
  2. Go to the Events page by following the steps shown in Figure 1.

    Figure 1 Events page

  3. Select the Search tab. Select a website from the All protected websites drop-down list, or select an instance from the All instances drop-down list, and choose to view protection events for Yesterday, Today, Past 3 days, Past 7 days, Past 30 days, or a custom time range. For details about parameters, see Table 1 and Table 2. Figure 2 shows an example.

    Figure 2 Viewing protection events
    Table 1 Event parameters

    Parameter

    Description

    Event Type

    Type of attack.

    By default, All is selected. You can view logs of all attack types or select an attack type to view corresponding attack logs.

    Protective Action

    The options are Block, Log only, and Verification code.

    Source IP Address

    Public IP address of the web visitor/attacker

    By default, All is selected. You can view logs of all attack source IP addresses, select an attack source IP address, or enter an attack source IP address to view corresponding attack logs.

    URL

    Attacked URL

    Event ID

    ID of the event

    Table 2 Log list parameters

    Parameter

    Description

    Time

    When an attack occurred

    Source IP Address

    Public IP address of the web visitor/attacker

    Geolocation

    Location where the IP address of the attack originates from

    Domain Name

    Attacked domain name

    URL

    Attacked URL

    Malicious Load

    The location or part of the attack that causes damage or the number of times that the URL was accessed.

    For example, the expression id=1' or 1=1 in an SQL injection attack.

    In a CC attack, the malicious load indicates the number of times that the URL was accessed.

    Event Type

    Type of attack

    Protective Action

    The options are Block, Log only, Verification code, and Mismatch.

    NOTE:

    If an access request matches a web tamper protection rule, information leakage prevention rule, or data masking rule, the protective action is marked as Mismatch.

    To view event details, click Details in the Operation column of the event list.

  4. After you confirm that an event is a false alarm, click Handle False Alarm in the Operation column of the row and add a false alarm masking rule by referring to Table 3. Figure 3 shows an example.

    Figure 3 Handling a false alarm
    Table 3 Parameter description

    Parameter

    Description

    Example Value

    Domain Name

    Domain name where an attack occurred. WAF auto-fills the field.

    None

    Path

    Part of the URL (excluding a domain name) that a false alarm is reported for. The default value is the source path of the event.

    • Prefix match: If you select Prefix is, the entered path is used as the prefix. For example, if the path to be protected is /admin/test.php or /adminabc, set Path to /admin.
    • Exact match: The path to be entered must be Equal to the path to be protected. For example, if the path to be protected is /admin/test.php, set Path to /admin/test.php.
    NOTE:
    • The path supports prefix and exact matches. Regular expressions are not supported.
    • The path cannot contain two or more consecutive slashes. For example, ///admin. If you enter ///admin, WAF converts /// to /.

    None

    Rule

    The item that the false alarm masking rule takes effect for. The options are:

    • ID: Configure the rules by event ID.
    • Attack type: Configure the rule by attack type.
    • All built-in rules: all checks enabled in Basic Web Protection.

    Attack type

    ID

    ID of a built-in rule, which is automatically read.

    This parameter is mandatory when Rule is set to ID.

    060015

    Attack Type

    Automatically obtained attack type.

    This parameter is mandatory when Rule is set to Attack type.

    Remote File Inclusion

    Rule Description

    A brief description of the rule. This parameter is optional.

    SQL injection attacks are not intercepted.

    Advanced Settings

    To ignore attacks of a specific field, specify the field in the Advanced Settings area. After you add the rule, WAF will stop blocking attack events of the specified field.

    Select a target field from the first drop-down list box on the left. The following fields are supported: Params, Cookie, Header, Body, and Multipart.
    • If you select Params, Cookie, or Header, configure subfields as required.
    • If you select Cookie, the Domain Name and Path can be empty.
    NOTE:

    If All is selected, WAF will not block all attack events of the selected field.

    Params

    All

  5. Click OK.

Verification

A false alarm will be deleted within about a minute after the handling configuration is done. It will no longer be displayed in the attack event details list. You can clear the cache, refresh the browser, and access the page again to verify whether the alarm was successfully handled.

Other Operations

If an event is handled as a false alarm, the corresponding rule will be added to the false alarm masking rule list. You can view, disable, delete, or modify the rule on the False Alarm Masking page under Policies. For more details, see Configuring a False Alarm Masking Rule.