tencent cloud

Web Application Firewall

Protection Modules

Unduh
Mode fokus
Ukuran font
Terakhir diperbarui: 2026-11-09 15:30:51
Diterjemahkan & Diperiksa oleh AI

Feature Overview

You can enable and configure the following protection modules as needed. All protection modules on this page are global policies that take effect for all scenarios under the current domain after configuration. Among them, the BOT allowlist has the highest priority, and traffic that matches the allowlist will skip subsequent BOT detection rules.
This document describes the feature principles and global configuration methods of each module. For specific operation steps and case analysis of each module in scenarios, see BOT Scenario-Based Practice Tutorial.
Note:
All protection module features are global configurations that take effect for all scenarios under the current domain after configuration. Among them, browser bot defense and bot analytics can be disabled separately in scenario configurations. If a scenario is not applicable, you can choose not to enable them in that scenario. For specific configuration methods, see Single Scene and Multi-Scene Mode.

Browser Bot Defense

Feature Introduction

Attention:
Browser Bot Defense technology is only applicable to Web or HTML5 environments. It does not currently support mobile apps or mini programs.
Browser Bot Defense is not currently supported for domains added to CLB-WAF instances.
Browser Bot Defense is not currently supported for wildcard domains added to SaaS-WAF instances.
Browser Bot Defense takes precedence over CC Protection. Requests blocked by Browser Bot Defense (HTTP 403) do not enter the CC Protection process. Therefore, 403 status codes in attack logs may come from Browser Bot Defense rather than CC Protection. By design, enabling Browser Bot Defense inserts JavaScript into responses, which may slightly increase bandwidth usage between WAF and the origin server.
Browser Bot Defense detects bot and malicious crawler behavior in Web or HTML5 page access by generating a unique ID and dynamic Token for each client.
Compatibility Note: Browser Bot Defense is applicable to web or HTML5 business protection. When the Content-Type of a POST response body is not text/html and does not contain the <html> tag, browser bot defense dynamic detection may be abnormal. In this case, you can add the request path or response request to the allowlist.
Interactive Browser Bot Defense: It displays a Captcha (slider, puzzle, character comparison, and so on) to the client to distinguish between human and BOT access behavior, and blocks the access after a certain number of verification failures. It is suitable for protecting core website interfaces (such as shopping cart, payment, and SMS APIs). This capability has been integrated into the action processing of various WAF modules (monitoring, CAPTCHA, redirection, and blocking).
Silent Browser Bot Defense: It completes client behavior detection without user awareness, making it suitable for scenarios that require a high user experience. After detecting traffic flooding or malicious crawler behavior, you can configure handling actions as needed.

Configuration Description

The Browser Bot Defense switch is disabled by default. After you enable it, WAF provides Browser Bot Defense protection for pages within the effective scope, identifies possible crawler behavior in client requests, and applies corresponding handling actions to requests identified as crawler behavior.
On the BOT Management > BOT Rule Configuration page, click Configure now in the Browser Bot Defense module of Global Settings to configure the following options:
Webpage anti-debugging: Enabled by default. When a user opens the browser developer tools, debug tracking is blocked on the page. It is recommended to enable this protection feature for sensitive directories that require protection.
Automated identification: Enabled by default. After it is enabled, it assists in dynamic threat detection.
Minimal Protection: A lightweight protection mode of Browser Bot Defense. After it is enabled, you need to configure the protection path scope (up to 20 paths). JavaScript is inserted only into response pages within the scope.
Attention:
In Minimal Protection mode, the protection strength is lower than that of the default protection mode. Enable it with caution.
Allowlist policies: You can add entries to the allowlist. The fields are described as follows:
Field Name
Description
Type
Request allowlist: Website URL pages that are added to the allowlist do not require dynamic security detection.
Response allowlist: By default, WAF inserts JavaScript into response pages based on business conditions. You can specify pages where JavaScript is not inserted to improve website compatibility.
Condition
Supports Path suffix match, Equal to, Start with and Include. Default: Path suffix match.
Content
When the match condition is Path suffix match, the system provides the file suffix names that need to be added to the allowlist by default, including: ico, gif, bmp, htc, jpg, jpeg, png, tiff, swf, js, css, rm, rmvb, wmv, avi, mkv, mp3, mp4, ogg, wma, zip, exe, rar, eot, woff, woff2, ttf, svg. You can modify them based on actual conditions. If you enter other match conditions, enter the allowlist path based on actual conditions.
Rule Description (Optional)
Enter the rule description.
On/Off
Disabled by default. You can adjust it based on actual conditions.

Bot Analytics

The Bot Analyticsmodule contains four submodules: Threat Intelligence, AI Policy, Smart Statistics, and UA Policy. It identifies BOT behavior from multiple dimensions. Bot Analytics is enabled by default (all four submodules are enabled), and the corresponding action policy ID is recorded for matched traffic.
On the BOT Management > BOT Rule Configuration page, click Configure now in the Bot Analytics module of Global Settings to enable or disable the analysis switch of each submodule. After a submodule is disabled, it no longer analyzes the corresponding policies and is not included in the BOT score evaluation. The detection results of the four submodules are aggregated into a BOT score, and the action policy mode then determines the final handling action. You can switch between preset modes such as Loose, Medium, and Strict, or use a custom mode. The score ranges, execution actions, and tags of each mode can be modified. For detailed configuration, see Action Policy.

Threat Intelligence

Threat Intelligence contains two types of intelligence: IDC network and threat intelligence library, which are continuously updated 24/7. On the Threat Intelligence Configuration page, you can control the switch of each identification item individually, or Enable/Disable all identification items with one click. When you enable Threat Intelligence for the first time, all identification items are enabled by default.
Practical Recommendations: Threat Intelligence can identify risky access such as malicious crawlers, distributed crawlers, proxies, credential stuffing, and fraudulent activities. It is recommended to keep it enabled at all times.
ToC Business (user requests are mainly initiated from residential IPs or base station IPs): After it is enabled, you can configure detection rules for proxy/IDC access in CAPTCHA Settings through custom session policies, and add callback APIs and business IDC addresses to the trust list to avoid false interception.
ToB Business (user requests are mainly initiated from IDCs or enterprise egress): After it is enabled, disable the identification item for the expected business IDC. Other configurations are the same as those for ToC Business.

AI Policies

The AI policy transforms risk control features and anti-fraud experience into an evaluation model to identify malicious visitors. If false positives are found in AI detection, you can click Add to Allowlist to add specific URLs to the allowlist and reduce false positives.
Note:
The AI policy allowlist here only affects the AI policy module and does not affect the normal detection of other modules.
Practical Recommendations: The AI policy can identify general BOTs and advanced persistent threat BOTs. It is recommended to keep it enabled at all times and add business callback APIs to the allowlist.
Field Name
Description
Rule Name
Name of the policy.
Rule Description
Description of the policy.
Allowlisted URL
The allowlist path of the AI policy affects the scoring result of the AI policy.
On/Off
Switch of the AI policy allowlist. When the switch is enabled, the current AI policy allowlist takes effect. When a URL matches the AI policy allowlist, the AI policy does not increase its score, and its BOT evaluation score is provided by threat intelligence and smart statistics.

Smart Statistics

Smart Statistics automatically classifies traffic based on the traffic characteristics of the domain's user groups, distinguishing normal users from malicious users. On the Smart Statistics page, you can configure detection levels and rule switches for features such as average session speed, session duration, URL types, UserAgent types, Cookie types, Referer types, and total number of sessions. A higher detection level provides higher precision but a lower detection rate, while a lower level provides a higher detection rate but lower precision. After a detection item is disabled, it no longer contributes to the BOT score.
Practical Recommendations: Smart Statistics can identify abnormal access behavior. It is recommended to keep it enabled at all times and set the rule level to Intelligent Recommendation.

UA Policies

The UA policy identifies the types and characteristics of different UAs to detect malicious terminals. On the UA Policy Configuration page, you can control the switch of each identification item individually, or enable/disable all identification items with one click.
Practical Recommendations: The UA policy can classify multiple client types. It is recommended to enable it when you need to distinguish terminal sources and identify malicious automation tools, and configure UA type observation rules based on business access characteristics.

Session Management

The session management feature is similar to the Session settings in CC Protection. By configuring different session identifiers, it distinguishes the behaviors of different visitors under the same IP address and collects statistics on the behavior characteristics of each visitor separately. This resolves the issue of being unable to precisely handle BOTs under residential IPs or public egress IPs, as well as the issue of being unable to collect session characteristics when proxy IPs change rapidly.
Session management includes two tabs: Session Identifier Configuration and Session ID Set.
1. On the BOT Management > BOT Rule Configuration page, click Configure now in the session management module of Global Configuration.
2. On the Session Management page, configure session identifiers or manage session ID sets as needed.

Session Identifier Configuration

1. On the Session Identifier Configuration tab, click Add policy, configure the relevant parameters, and then click OK.
Note:
The session identifier should be a persistent tokenid, such as the value of set-cookies after login.
Field Name
Description
Session Identifier Name
Custom description name, up to 128 characters.
Session Identifier Description
Custom description text, up to 128 characters.
Session Identifier Location
Specify the parameter name in a specific location (QUERY, BODY, COOKIE, or HEADERS) as the session identifier, and use the value corresponding to that parameter name as the session ID.
Session Identifier Parameter
Supports using the . character to separate parameters at each level. Example:
test: Identifies the value of the test parameter in a JSON string as the session ID.
test1.test2: In a JSON string, identifies the value of the test2 parameter nested within the test1 object as the session ID through the path test1.test2.
Disable Nested Parsing
By default, the system enables nested parsing for QUERY, BODY, and HEADERS, while the COOKIE field does not support nested parsing. The parsing feature for HEADERS cannot be disabled, while QUERY and BODY can be disabled as needed.
On/Off
Default enabled status of the rule.
Advanced Settings
Click Advanced settings to configure. If not specifically set, the settings are applied to all scenarios by default with a priority of 1.
Application scenarios: It supports selecting All scenes or Some scenarios, and the rules take effect on the selected scenarios.
Priority: Enter an integer from 1 to 100. A smaller value indicates a higher priority, and the corresponding session identifier is matched first. If priorities are the same, the most recently updated one takes precedence.
Session validity verification: It supports verifying the validity of the extracted session ID value and provides the following verification methods:
JWS/JWE verification: Configure decryption for content encrypted using JSON Web Token and verify its validity. This applies to scenarios where tokens are transmitted after being processed using JWT.
Containment verification: Configure a target substring, and the system verifies whether the token fully contains this substring (position not limited). This applies to business scenarios where the token contains a key segment that can identify its validity.
Length verification: Configure a target length, and the system verifies whether the extracted token length meets a specific length requirement. This applies to business scenarios where only simple token validity verification is needed.
Regular expression verification: Configure a regular expression that complies with the PCRE specification, and the system uses this expression to perform pattern matching verification on the entire token. This applies to business scenarios where the token format is complex and flexible custom verification rules are required.
2. The configuration takes effect automatically after it is completed, and BOT traffic analysis will start analyzing traffic based on the field where the session identifier is located.

Session ID Set

1. On the Session ID Set tab, click New. The fields are described as follows:
Collection Name: Enter a set name.
Description: Enter the description.
Session ID: Enter session IDs, one per line, with a maximum of 1000 lines.
2. You can also click Import Data to import session ID sets in batches.
Format: Only .xlsx and .xls formats are supported, and only one file can be uploaded at a time.
Quantity: You can import up to 50 records at a time. If you need to import a large number of records, import them in multiple batches.
Content: The file must contain a session ID set name column and a session ID column. The description column is optional. For the specific field format, refer to the exported Excel format.
3. Click Upload/Drag and drop the file in this area to upload an .xlsx or .xls file (up to 1.5 MB). You can also click Download Import Template to obtain the standard template.
4. After configuring the relevant parameters, click OK.

Good Bots

1. On the BOT Management > BOT Rule Configuration page, click Configure now for Legitimate Crawlers in the Global Configuration module.
2. On the Legitimate Crawlers page, use the toggle to allow BOTs that are beneficial to website data, ensuring that the website is not affected when being indexed by search engines and external partner crawlers.

CAPTCHA Settings

1. On the BOT Management > BOT Rule Configuration page, click Set now for CAPTCHA Settings in the Global Configuration module.
2. In the Global settings for CAPTCHA, configure the relevant parameters and click OK.
Configuration Item
Description
Retry Count
Range: 1-100. The number of retries. If the verification still fails after the maximum number of retires is reached, the access is intercepted.
Releasing Duration
Range: 1-10080 minutes. The IP address can be released (without calling up the verification page) for a specified releasing duration after a single successful verification.
Interception Duration
Range: 1-10080 minutes. When the maximum number of retries is reached, the IP address is intercepted. The interception duration can be specified.
Advanced Configurations
Custom headers are supported. When forced caching policy is enabled on CDN, a feature Header (such as X-WAF-Challenge) can be added to allow CDN to identify and skip Captcha page caching. Up to 10 entries can be added.
Note:
Custom Header configuration is not supported for domains connected to cloud-native instances. Reserved headers such as Host and Content-Length cannot be used.
3. After configuration, the rules with the protection action set to CAPTCHA or Precise Captcha under this domain take effect, including rules in the Basic Security and BOT Management modules.

BOT Allowlist

The BOT allowlist has a higher priority than all scenario configurations. Traffic that matches the allowlist will skip subsequent BOT detection rules.
1. On the BOT Management > BOT Rule Configuration > BOT Allowlist page, click Add Rule, configure the relevant parameters, and then click OK.
Field Name
Description
Rule Name
Policy name field.
Rule Description
Policy description field.
On/Off
Policy switch status. Enabled by default.
Condition
Set match conditions for a BOT policy. You can set up to 10 match conditions, and the conditions are in an AND relationship. When you hover over a specific match condition, you can view its description.
Priority
Enter an integer from 1 to 100. A smaller value indicates a higher execution priority of this rule. For the same priority, a later creation time indicates a higher priority.
Custom Tag
Friendly bot, Normal.
Note:
Friendly BOTs have the highest priority. Once matched, traffic is directly allowed and skips all subsequent BOT detection rules.
Option
Permanent: It takes effect permanently for all time.
Scheduled Effectiveness: It takes effect according to the specified daily time periods.
Weekly Granularity Effective: It takes effect according to specific days and time periods each week.
Monthly Granularity Effective: It takes effect according to specific dates and time periods each month.
2. After the rule is added, you can view it in the policy list. Click Edit or Delete to edit or delete the rule.

Bantuan dan Dukungan

Apakah halaman ini membantu?

masukan