This section describes how to configure precise protection rules.
With these rules, WAF allows you to customize combinations of HTTP headers, cookies, URLs, request parameters, and IP addresses, improving defense accuracy.
In the upper part of the domain name list, click Quota details to view the domain name quota.
If you do not click Save after changing Status in Step 5, a Warning dialog box is displayed when you click Customize Rule.
The default detection mode is Instant Detection. After changing the detection mode, click Save.
In the upper part of the protection rule list, click Quota details to view the quota of protection rules.
Parameter |
Description |
Example Value |
---|---|---|
Rule Name |
Customizable rule name |
waftest |
Protective Action |
Its value is Block or Allow. The default value is Block. |
Block |
Effective Since |
Select Immediately or select Customize to set a period. This period can only be a time segment in the future. |
Immediately |
Condition List |
Click Add to add conditions. You must add one to thirty conditions to a protection rule. If more than one condition is added, all the conditions must be met simultaneously for the rule to take effect.
NOTE:
For detailed configurations, see Table 2. |
|
Priority |
Priority of a rule being executed Smaller values correspond to higher priorities. If two rules are assigned with the same priority, the rule added earlier has higher priority. |
50 |
Field |
Example Subfield |
Logic |
Example Content |
---|---|---|---|
Path: URL excluding a domain name. This value supports exact match only. For example, if the path to be protected is /admin, set Path to /admin. |
None |
Include, Exclude, Equal to, Not equal to, Prefix is, Prefix is not, Suffix is, or Suffix is not |
/buy/phone/ |
User Agent: A user agent of the scanner to be protected |
None |
Include, Exclude, Equal to, Not equal to, Prefix is, Prefix is not, Suffix is, or Suffix is not |
Mozilla/5.0 (Windows NT 6.1) |
IP: An IP address of the visitor to be protected |
None |
Equal to or Not equal to |
192.168.2.3 |
Params: A request parameter to be protected |
sttl |
Include, Exclude, Equal to, Not equal to, Prefix is, Prefix is not, Suffix is, or Suffix is not |
201901150929 |
Cookie: A small piece of data to identify web visitors |
name |
Include, Exclude, Equal to, Not equal to, Prefix is, Prefix is not, Suffix is, or Suffix is not |
Nessus |
Referer: A user-defined request resource For example, if the protected path is /admin/xxx and you do not want visitors to access the page from www.test.com, set Content to http://www.test.com. |
None |
Include, Exclude, Equal to, Not equal to, Prefix is, Prefix is not, Suffix is, or Suffix is not |
http://www.test.com |
Header: A user-defined HTTP header |
Accept |
Include, Exclude, Equal to, Not equal to, Prefix is, Prefix is not, Suffix is, or Suffix is not |
text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8 |