Get a list of exceptions for the WAF rules.
| Name | Description |
|---|---|
serviceTypeString | Security service type. Please enter a specific service type, if you purchase multiple security services. |
| Name | Description |
|---|---|
*domainListList | Domain list. |
*ruleIdListList | WAF rule ID list. |
| Name | Description |
|---|---|
codeString | Optional Value: Parameter Values Please refer to the error code for exceptions. |
msgString | Description. |
dataList | Data. |
idString | Rule exception ID. |
domainString | Domain. |
ruleIdInteger | WAF rule ID. |
typeString | Optional Value: ippathuriurlParamNameurlParamValueuserAgenthttpHeaderNamehttpHeaderValuecookiebodybodyParamNamebodyParamValue Matching conditions.
ip: IP
path: Path
uri: URI
urlParamName: URI Parameter Name
urlParamValue: URI Parameter Value
userAgent: User Agent
httpHeaderName: Request Header Name
httpHeaderValue: Request Header Value
cookie: Cookie
body: Body
bodyParamName: Body Parameter Name
bodyParamValue: Body Parameter Value |
matchTypeString | Optional Value: EQUALCONTAINREGEX Match type,IP can only be EQUAL.
EQUAL: Equal
CONTAIN: Contains
REGEX: Regular match |
contentListList | Rule exceptions.
When matchType=EQUAL, case-sensitive. |
| Error code(code) | Description(message) | HTTP status | Semantic |
|---|---|---|---|
| 40010 | Request\nparameter\nerror. | 200 | Request\nparameter\nerror. |
| 500 | Server\nerror. | 200 | Server\nerror. |
#!/bin/bash
username="example_username"
# Note that this must be a single quote to avoid the special $ character
apiKey='example_apiKey'
date=`env LANG="en_US.UTF-8" date -u "+%a, %d %b %Y %H:%M:%S GMT"`
password=`echo -en "$date" | openssl dgst -sha1 -hmac $apiKey -binary | openssl enc -base64`
curl -i --url "https://api.cdnetworks.com/api/v1/waf/rule-exception/list-normal" \
-X "POST" \
-u "$username:$password" \
-H "Date: $date" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"domainList": [
"waap.example.com"
],
"ruleIdList": [
5005
]
}'{
"code": 200,
"msg": "Success",
"data": [
{
"id": "1234567890123456789",
"domain": "waap.example.com",
"ruleId": 5005,
"type": "ip",
"matchType": "EQUAL",
"contentList": [
"1.1.1.1"
]
}
]
}