You can call this operation to enable tamper protection for a directory of a specific server.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ModifyWebLockCreateConfig

The operation that you want to perform.

Set the value to ModifyWebLockCreateConfig.

SourceIp String No 1.2.3.4

The source IP address of the request.

Lang String No zh

The language of the request and response. Valid values:

  • zh: Chinese
  • en: English
Uuid String No inet-12345****

The UUID of the server to which you want to add a protected directory.

Dir String No /home/admin/tomcat

The directory for which you want to enable tamper protection.

ExclusiveDir String No /home/admin/test

The directory for which you want to disable tamper protection.

Note If the value of Mode is blacklist, you must set this parameter.
ExclusiveFileType String No jpg

The types of files for which you want to disable tamper protection. Separate multiple file types with semicolons (;). Valid values:

  • *.php
  • *.jsp
  • *.asp
  • *.aspx
  • *.js
  • *.cgi
  • *.html
  • *.htm
  • *.xml
  • *.shtml
  • *.shtm
  • *.jpg
  • *.gif
  • *.png
Note If the value of Mode is blacklist, you must set this parameter.
LocalBackupDir String No /usr/local/backup

The local path where backup files of the protected directory are stored.

Mode String No whitelist

The protection mode. Valid values:

  • whitelist: In this mode, tamper protection is enabled for the specified directories and file types.
  • blacklist: In this mode, tamper protection is enabled for the unspecified sub-directories, file types, and files under the protected directory.
InclusiveFileType String No jpg

The types of files for which you want to enable tamper protection. Separate multiple file types with semicolons (;). Valid values:

  • *.php
  • *.jsp
  • *.asp
  • *.aspx
  • *.js
  • *.cgi
  • *.html
  • *.htm
  • *.xml
  • *.shtml
  • *.shtm
  • *.jpg
  • *.gif
  • *.png
Note If Mode is set to whitelist, you must set this parameter.
ExclusiveFile String No /home/admin/apache.log

The files for which you want to disable tamper protection.

Note If Mode is set to blacklist, you must set this parameter.
InclusiveFile String No /home/admin/test.log

The files for which you want to enable tamper protection.

Note If the value of Mode is whitelist, you must set this parameter.

Response parameters

Parameter Type Example Description
RequestId String D9354C1A-D709-4873-9AAE-41513327B247

The ID of the request.

Examples

Sample requests

http(s)://[Endpoint]/? Action=ModifyWebLockCreateConfig
&<Common request parameters>

Sample success responses

XML format

<ModifyWebLockCreateConfigResponse>
      <requestId>D9354C1A-D709-4873-9AAE-41513327B247</requestId>
</ModifyWebLockCreateConfigResponse>

JSON format

{
    "requestId": "D9354C1A-D709-4873-9AAE-41513327B247"
}

Error codes

For a list of error codes, visit the API Error Center.