Queries the port details of cloud service instances that are connected to WAF.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
yundun-waf:DescribeCloudResourceAccessPortDetails |
get |
*All Resource
|
|
None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
The ID of the WAF instance. Note
You can call DescribeInstance to query the ID of the current WAF instance. |
waf-cn-tl32ast**** |
| ResourceManagerResourceGroupId |
string |
No |
The ID of the Alibaba Cloud resource group. |
rg-acfm***q |
| ResourceInstanceId |
string |
Yes |
The instance ID of the resource. |
lb-2zeugkfj81jvo****4tqm |
| Port |
string |
No |
The port of the cloud service that is connected to WAF. |
443 |
| Protocol |
string |
No |
The protocol type. Valid values:
|
https |
| PageNumber |
integer |
No |
The page number of the list. Default value: 1. |
1 |
| PageSize |
integer |
No |
The number of entries per page in a paged query. Default value: 10. |
10 |
| ResourceProduct |
string |
No |
The cloud service type. Valid values:
|
clb7 |
| RegionId |
string |
No |
The region where the WAF instance resides. Valid values:
|
cn-hangzhou |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
2EFCFE18-78F8-5079-B312-07***48B |
| TotalCount |
integer |
The total number of entries returned. |
10 |
| AccessPortDetails |
array<object> |
The port details of cloud service instances connected to WAF. |
|
|
array<object> |
The port details of cloud service instances connected to WAF. |
||
| Protocol |
string |
The protocol type. Valid values:
|
https |
| Port |
integer |
The port of the cloud service that is connected to WAF. |
443 |
| Certificates |
array<object> |
The list of certificates for the cloud service port connected to WAF. |
|
|
object |
The certificate information for the cloud service port connected to WAF. |
||
| CertificateName |
string |
The certificate name. |
cert-name1 |
| CertificateId |
string |
The ID of the added certificate. |
123-cn-hangzhou |
| AppliedType |
string |
The certificate type for the HTTPS protocol. Valid values:
|
default |
| XffHeaderMode |
integer |
The method that WAF uses to obtain the originating IP address of the client. Valid values:
|
0 |
| XffHeaders |
array |
The list of custom header fields used to obtain the client IP address, in the format ["header1","header2",……]. Note
This parameter is required only when XffHeaderMode is set to 2 (WAF reads the value of a custom header field that you specify as the client IP address). |
|
|
string |
The list of custom header fields used to obtain the client IP address, in the format ["header1","header2",……]. Note
This parameter is required only when XffHeaderMode is set to 2 (WAF reads the value of a custom header field that you specify as the client IP address). |
header1 |
|
| LogHeaders |
array<object> |
The traffic tag fields and values of the domain name, used to mark traffic processed by WAF. Note
This parameter is returned only when the traffic tag feature is enabled for the domain name. |
|
|
object |
The traffic tag fields and values of the domain name, used to mark traffic processed by WAF. Note
This parameter is returned only when the traffic tag feature is enabled for the domain name. |
||
| Key |
string |
The specified custom request header field. |
key1 |
| Value |
string |
The value of the specified custom request header field. |
value1 |
| Status |
integer |
The domain name status. Valid values:
|
1 |
| TLSVersion |
string |
The TLS version. Valid values:
|
tlsv1 |
| EnableTLSv3 |
boolean |
Indicates whether TLS 1.3 is supported. Valid values:
Note
This parameter is used only when HttpsPorts is not empty (the domain name uses the HTTPS protocol). When TLSVersion is set to tlsv1.3, this value must be true. |
true |
| CipherSuite |
integer |
The cipher suite type. Valid values:
|
1 |
| CustomCiphers |
array |
The specific custom cipher suites to add. This parameter is used only when CipherSuite is set to 99. |
|
|
string |
The custom cipher suite. |
ECDHE-RSA-AES256-SHA:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-SHA384 |
|
| ReadTimeout |
integer |
The read timeout period, in seconds. Valid values: 1 to 3600. |
5 |
| WriteTimeout |
integer |
The write timeout period, in seconds. Valid values: 1 to 3600. |
1 |
| Keepalive |
boolean |
Indicates whether keep-alive connections are enabled. Valid values:
|
true |
| KeepaliveRequests |
integer |
The number of requests that can reuse a keep-alive connection. Valid values: 60 to 1000. Note
Specifies how many requests can reuse a keep-alive connection after keep-alive is enabled. |
1000 |
| KeepaliveTimeout |
integer |
The idle timeout period for keep-alive connections. Valid values: 10 to 3600. Default value: 15. Unit: seconds. Note
Specifies how long an idle keep-alive connection remains open before it is released. |
10 |
| Http2Enabled |
boolean |
Indicates whether HTTP/2 is enabled. Valid values:
|
True |
| XffProto |
boolean |
Specifies whether the X-Forward-For-Proto header passes the WAF protocol. Valid values:
|
true |
| OwnerUserId |
string |
The UID of the cloud service resource ownership. |
123 |
| SubStatus |
string |
The protection exception status. Valid values:
|
InvalidCert |
| SubStatusDetails |
array<object> |
The specific reasons for the protection exception status. This parameter has a value only when SubStatus is set to InvalidCert. |
|
|
object |
The specific reasons for the protection exception status. This parameter has a value only when SubStatus is set to InvalidCert. |
||
| CertName |
string |
The certificate name in SSL Certificates Service. |
test-name |
| Domain |
string |
The domain name bound to the certificate. |
test.aliyun.com |
| CertId |
string |
The certificate ID in SSL Certificates Service. |
123-cn-hangzhou |
| AppliedType |
string |
The certificate type for the HTTPS protocol. Valid values:
|
default |
| ProductCertName |
string |
The certificate name stored in the cloud service. |
test-name |
| ProductCertId |
string |
The certificate ID stored in the cloud service. |
123 |
| CommonName |
string |
The common name (CN). |
test.aliyun.com |
| ReasonCode |
string |
The specific reason for the protection exception status. Valid values:
|
CertNotExistInCertCenter |
| ExpireTime |
integer |
The expiration time of the certificate, in UNIX timestamp format. Unit: seconds. |
1746328456000 |
| CloudResourceId |
string |
The ID of the connected resource, automatically generated by WAF. |
i-bp1**************7ey-80-ecs |
| MaxBodySize |
integer |
The maximum request body size. Valid values: 2 to 10. Default value: 2. Unit: GB. |
2 |
Examples
Success response
JSON format
{
"RequestId": "2EFCFE18-78F8-5079-B312-07***48B",
"TotalCount": 10,
"AccessPortDetails": [
{
"Protocol": "https",
"Port": 443,
"Certificates": [
{
"CertificateName": "cert-name1",
"CertificateId": "123-cn-hangzhou",
"AppliedType": "default"
}
],
"XffHeaderMode": 0,
"XffHeaders": [
"header1"
],
"LogHeaders": [
{
"Key": "key1",
"Value": "value1"
}
],
"Status": 1,
"TLSVersion": "tlsv1",
"EnableTLSv3": true,
"CipherSuite": 1,
"CustomCiphers": [
"ECDHE-RSA-AES256-SHA:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-SHA384"
],
"ReadTimeout": 5,
"WriteTimeout": 1,
"Keepalive": true,
"KeepaliveRequests": 1000,
"KeepaliveTimeout": 10,
"Http2Enabled": true,
"XffProto": true,
"OwnerUserId": "123",
"SubStatus": "InvalidCert",
"SubStatusDetails": [
{
"CertName": "test-name",
"Domain": "test.aliyun.com",
"CertId": "123-cn-hangzhou",
"AppliedType": "default",
"ProductCertName": "test-name",
"ProductCertId": "123",
"CommonName": "test.aliyun.com",
"ReasonCode": "CertNotExistInCertCenter",
"ExpireTime": 1746328456000
}
],
"CloudResourceId": "i-bp1**************7ey-80-ecs",
"MaxBodySize": 2
}
]
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | Waf.Instance.ValidFaild | WAF instance check failed. Check whether the instance ID is correct. | WAF instance check failed. Check whether the instance ID is correct. |
| 400 | Waf.Pullin.CloudProductParamEmpty | The resource Id of the cloud product accessing WAF is null or null values exist in the three input parameters of the cloud product name, port, and cloud product instance. | The resource Id of the cloud product accessing WAF is null or null values exist in the three input parameters of the cloud product name, port, and cloud product instance. |
| 400 | Waf.Pullin.CloudResourceInvalid | CloudResourceId parameter is illegal. | CloudResourceId parameter is illegal |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.