docs
api
Web Application Firewall(UEWAF)
AddWafDomainHostInfo

Add new protection domain configuration - AddWafDomainHostInfo

Overview

Add new protection domain configuration

Definition

Public Parameters

Parameter NameTypeDescription InformationRequired
ActionstringCorresponding API command name, the current API is AddWafDomainHostInfo.Yes
PublicKeystringThe user's public key can be obtained from Console (opens in a new tab)Yes
SignaturestringUser signature generated based on public key and API command, see Signature AlgorithmYes

Request Parameters

Parameter NameTypeDescription InformationRequired
ProjectIdstringProject ID. If not filled in, the default project is used, and the sub-account must be filled in. Please refer to the GetProjectList interface.No
FullDomainstringDomain to be protectedYes
WorkRegionsstringWorkspace, a subset of the areas purchased by the user, separated by commas, such as: cn-bj,cn-shYes
WorkModestringWorking Mode, Defence: Enable Protection Rules, Alarm: Record without Blocking, Inactive: Allow; Default AlarmNo
SrcIP.NstringOrigin IP port information, format is: http://192.168.1.1 (opens in a new tab) or http://192.168.1.1:80 (opens in a new tab); compatible with http:192.168.1.1:80, supports CNAMENo
CertificateIDintHTTPS certificate number, required when the origin prefix is httpsNo
HTTPRedirectionstringUse HTTP redirection, YES for enabled, NO for disabled. Only allowed to use in situations where HTTPS:YES, HTTP:NO and only the source station configured with https 443 port is set up.No
ExclusiveIPstringIndicates that this domain name uses a dedicated defense IP, YES for yes, NO for no; enabling will assign a dedicated defense IP to this domain name.No
RealIPHeaderstringObtain the real client address field, used when docking with other proxies such as CDN.No
HTTPBackstringUse HTTPS offloading, YES/NONo
SourceIndicatestringTraffic tagging, format as key:valueNo
Http2stringEnable HTTP2? YES to enable, others to disable.No
SrcLBModestringOrigin server load balancing strategy, default is Round Robin (RR), options include: IpHash, RRNo

Response Field

Field NameTypeDescription InformationRequired
RetCodeintReturn status code. If it is 0, it means successful return. If it is not 0, it means failure.Yes
ActionstringOperation command name.Yes
MessagestringReturns an error message, providing detailed description when RetCode is non-zero.No
IdintDomain configuration ID returned after successful additionNo

Example

Request Example

https://api.surfercloud.com/?Action=AddWafDomainHostInfo
&ProjectId=org-xxx
&FullDomain=www.test.com
&WorkRegions=cn-gd
&SrcIPNum=1
&SrcIP.0=http://106.75.66.11:80
&CertificateID=0
&ExclusiveIP=No
&HTTPBack=jQqKWgcf
&SourceIndicate=VyxSQeOP
&HTTP2=pUmPZWTR
&SrcLBMode=sPEOjSVl

Response Example

{
  "Action": "AddWafDomainHostInfoResponse",
  "Id": 9,
  "RetCode": 0
}
  • Company
  • ContactUs
  • Blog
Copyright © 2024 SurferCloud All Rights Reserved