All Products
Search
Document Center

CreateMajorProtectionBlackIp

Last Updated: Aug 02, 2022

Creates an IP address blacklist for the protection for major events feature in WAF 3.0.

Operation Description

This operation is applicable only to the China site (aliyun.com).

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

Parameter

Type

Required

Description

Example

InstanceId

string

Yes

The ID of the WAF instance.

waf-cn-xx

TemplateId

Long

Yes

The ID of the protection template for the protection for major events feature.

2221

RuleId

Long

Yes

The ID of the IP address blacklist rule for the protection for major events feature.

232324

IpList

string

Yes

The IP addresses that are added to the IP address blacklist. CIDR blocks and IP addresses are supported. IPv4 and IPv6 addresses are supported. Separate multiple CIDR blocks or IP addresses with commas (,).

192.0.XX.XX,192.0.XX.XX/24

ExpiredTime

Long

Yes

The timestamp after which the IP address blacklist becomes invalid. Unit: seconds.

Note

If you set the value to 0, the blacklist is permanently valid.

1224123412432

Description

string

Yes

The description of the IP address blacklist.

Protection for major events

Response parameters

Parameter

Type

Description

Example

object

RequestId

string

The ID of the request.

D7861F61-5B61-46CE-A47C-6B19160D5EB0

Example

Request example

http(s)://[Endpoint]/?Action=CreateMajorProtectionBlackIp
&InstanceId=waf-cn-xx
&TemplateId=2221
&RuleId=232324
&IpList=192.0.2.0,192.0.2.254/24
&ExpiredTime=1224123412432
&Description=Protection for major events
&Common request parameters

Normal return example

JSON Format

{
  "RequestId": "D7861F61-5B61-46CE-A47C-6B19160D5EB0"
}

Error codes

For a list of error codes, visit the API error center.