All Products
Search
Document Center

Anti-DDoS:DescribeWebPreciseAccessRule

Last Updated:Oct 23, 2024

Queries the accurate access control rules that are created for websites.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
yundun-ddoscoo:DescribeWebPreciseAccessRuleget
  • All Resources
    *
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
ResourceGroupIdstringNo

The ID of the resource group to which the instance belongs in Resource Management. This parameter is empty by default, which indicates that the instance belongs to the default resource group.

default
DomainsarrayYes

An array that consists of the domain names of websites.

Note A forwarding rule must be configured for the domain name. You can call the DescribeDomains operation to query all domain names.
stringYes

The domain name of the website.

www.test****.com

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The ID of the request.

209EEFBF-B0C7-441E-8C28-D0945A57A638
PreciseAccessConfigListarray<object>

The configuration of the accurate access control rule that is created for the website.

PreciseAccessConfigobject
Domainstring

The domain name of the website.

www.aliyun.com
RuleListarray<object>

The scheduling rules.

Ruleobject
Actionstring

The action triggered if the rule is matched. Valid values:

  • accept: The requests that match the rule are allowed.
  • block: The requests that match the rule are blocked.
  • challenge: Completely Automated Public Turing test to tell Computers and Humans Apart (CAPTCHA) verification for the requests that match the rule is implemented.
accept
Ownerstring

The source of the rule. Valid values:

  • manual (default): manually created.
  • auto: automatically generated.
manual
Expireslong

The validity period of the rule. Unit: seconds. This parameter takes effect only when action of a rule is block. Access requests that match the rule are blocked within the specified validity period of the rule. The value 0 indicates that the whitelist takes effect all the time.

0
Namestring

The name of the scheduling rule.

testrule
ConditionListarray<object>

The match conditions.

Conditionobject
MatchMethodstring

The logical operator.

belong
Fieldstring

The match field.

ip
Contentstring

The match content.

1.1.1.1
HeaderNamestring

The custom HTTP request header.

Note This parameter takes effect only when Field is set to header.
null

Examples

Sample success responses

JSONformat

{
  "RequestId": "209EEFBF-B0C7-441E-8C28-D0945A57A638",
  "PreciseAccessConfigList": [
    {
      "Domain": "www.aliyun.com",
      "RuleList": [
        {
          "Action": "accept",
          "Owner": "manual",
          "Expires": 0,
          "Name": "testrule",
          "ConditionList": [
            {
              "MatchMethod": "belong",
              "Field": "ip",
              "Content": "1.1.1.1",
              "HeaderName": "null",
              "ContentList": [
                ""
              ]
            }
          ]
        }
      ]
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history