Help Center/ Host Security Service/ API Reference/ API Description/ Web Tamper Protection/ Querying Web Tamper Protection Configuration List
Updated on 2026-04-03 GMT+08:00

Querying Web Tamper Protection Configuration List

Function

This API is used to query the web tamper protection configuration list.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.

  • If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
  • If you are using identity policy-based authorization, no identity policy-based permission required for calling this API.

URI

GET /v5/{project_id}/webtamper/protection-configs

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Definition

Project ID, which is used to specify the project that an asset belongs to. After the project ID is configured, you can query assets in the project using the project ID. For details about how to obtain it, see Obtaining a Project ID.

Constraints

N/A

Range

The value can contain 1 to 256 characters.

Default Value

N/A

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

enterprise_project_id

No

String

Definition

Enterprise project ID, which is used to filter assets in different enterprise projects. For details, see Obtaining an Enterprise Project ID.

To query assets in all enterprise projects, set this parameter to all_granted_eps.

Constraints

You need to set this parameter only after the enterprise project function is enabled.

Range

The value can contain 1 to 256 characters.

Default Value

0: default enterprise project.

offset

No

Integer

Definition

Offset, which specifies the start position of the record to be returned.

Constraints

N/A

Range

The value range is 0 to 2,000,000.

Default Value

The default value is 0.

limit

No

Integer

Definition

Number of records displayed on each page.

Constraints

N/A

Range

Value range: 10-200

Default Value

10

type

Yes

String

Definition

Web tamper protection type.

Constraints

N/A

Range

  • container_wtp: container WTP

Default Value

N/A

id

No

String

Definition

Web tamper protection configuration ID.

Constraints

N/A

Range

The value can contain 1 to 128 characters.

Default Value

N/A

web_app_name

No

String

Definition

Website application name.

Constraints

N/A

Range

The value can contain 1 to 128 characters.

Default Value

N/A

image_name

No

String

Definition

Image

Constraints

N/A

Range

The value can contain 1 to 512 characters.

Default Value

N/A

image_version

No

String

Definition

Image version

Constraints

N/A

Range

The value can contain 1 to 128 characters.

Default Value

N/A

protect_type

No

String

Definition

Protection type.

Constraints

N/A

Range

  • cluster: protection within a cluster

  • host: protection within a server

Default Value

N/A

status

No

String

Definition

Protection status

Constraints

N/A

Range

  • not_protect: unprotected

  • protected: protected

  • partial_protected: partially protected

  • protect_failed: protection failed

  • redundant: redundant protection

Default Value

N/A

cluster_name

No

String

Definition

Cluster name.

Constraints

N/A

Range

The value can contain 0 to 256 characters.

Default Value

N/A

cluster_id

No

String

Definition

Cluster ID.

Constraints

N/A

Range

The value can contain 0 to 128 characters.

Default Value

N/A

host_name

No

String

Definition

Server Name

Constraints

N/A

Range

The value can contain 0 to 128 characters.

Default Value

N/A

host_id

No

String

Definition

Server ID.

Constraints

N/A

Range

The value can contain 0 to 128 characters.

Default Value

N/A

host_private_ip

No

String

Definition

Server private IP address

Constraints

N/A

Range

The value can contain 0 to 128 characters.

Default Value

N/A

Request Parameters

Table 3 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Definition

User token, which contains user identity and permissions. The token can be used for identity authentication when an API is called. For details about how to obtain the token, see Obtaining a User Token.

Constraints

N/A

Range

The value can contain 1 to 32,768 characters.

Default Value

N/A

Response Parameters

Status code: 200

Table 4 Response body parameters

Parameter

Type

Description

total_num

Integer

Definition

Total number of web tamper protection configurations.

Range

The value range is 0 to 2,147,483,647.

data_list

Array of WebTamperProtectionConfigResponseInfo objects

Definition

Web tamper protection configuration list.

Range

0 to 200 items

Table 5 WebTamperProtectionConfigResponseInfo

Parameter

Type

Description

id

String

Definition

Web tamper protection configuration ID.

Range

The value can contain 1 to 64 characters.

protect_mode

String

Definition

Protection mode.

Range

  • alarm: alarm mode

  • block: blocking mode

monitor_process

Boolean

Definition

Whether to monitor processes to check for tampering.

Range

  • true: Monitor tampering processes.

  • false: Do not monitor tampering processes.

privileged_process_list

Array of strings

Definition

List of privileged process paths.

Range

0 to 10 items

privileged_child

Boolean

Definition

Whether the subprocess of a privileged process still has privileges.

Range

  • true: The subprocess of a privileged process is still a privileged process.

  • false: The subprocess of a privileged process is no longer a privileged process.

protect_directory_info_list

Array of ProtectDirectoryResponseInfo objects

Definition

Protected directory information.

Range

1 to 50 items

exclude_file_types

Array of strings

Definition

List of excluded file types.

Range

0 to 10 items

status

String

Definition

Protection status

Range

  • not_protect: unprotected

  • protected: protected

  • partial_protected: partially protected

  • protect_failed: protection failed

  • redundant: redundant protection

protected_container_nums

Integer

Definition

Number of protected containers.

Range

The value range is 0 to 2,147,483,647.

protected_event_nums

Integer

Definition

Number of protection events generated by the current protection configuration.

Range

The value range is 0 to 2,147,483,647.

resource_id

String

Definition

Quota ID bound to the protection configuration.

Range

The value can contain 1 to 64 characters.

container_wtp_info

container_wtp_info object

Definition

Container web tamper protection information.

Range

N/A

Table 6 ProtectDirectoryResponseInfo

Parameter

Type

Description

protect_directory

String

Definition

Protected directory.

Range

The value can contain 1 to 256 characters.

exclude_child_directory_list

Array of strings

Definition

List of subdirectories to be excluded.

Range

0 to 10 items

exclude_file_list

Array of strings

Definition

List of subfiles to be excluded.

Range

0 to 10 items

backup_directory

String

Definition

Backup directory.

Range

The value can contain 1 to 256 characters.

Table 7 container_wtp_info

Parameter

Type

Description

web_app_name

String

Definition

Web Application Name

Range

The value can contain 1 to 128 characters.

image_name

String

Definition

Image

Range

The value can contain 1 to 512 characters.

image_version

String

Definition

Image version

Range

The value can contain 1 to 64 characters.

image_type

String

Definition

Image type.

Range

  • registry: repository image

  • local: local image

  • custom: custom image

protect_type

String

Definition

Protection type.

Range

  • cluster: web tamper protection for containers in a cluster

  • host: web tamper protection for containers on a server

cluster_info

cluster_info object

Definition

Cluster information corresponding to the protection configuration.

Range

N/A

cluster_label_list

Array of cluster_label_list objects

Definition

Cluster tag list

Range

0 to 10 items

host_info

host_info object

Definition

Server information corresponding to the protection configuration.

Range

N/A

Table 8 cluster_info

Parameter

Type

Description

cluster_id

String

Definition

Cluster ID.

Range

The value can contain 0 to 128 characters.

cluster_name

String

Definition

Cluster name.

Range

The value can contain 0 to 256 characters.

cluster_version

String

Definition

Cluster version.

Range

The value can contain 0 to 256 characters.

cluster_type

String

Definition

Cluster type.

Range

  • cce: CCE cluster

  • ali: Alibaba Cloud cluster

  • tencent: Tencent Cloud cluster

  • azure: Microsoft Azure Cloud cluster

  • aws: AWS Cloud cluster

  • self_built_hw: customer-built cluster on Huawei Cloud

  • self_built_idc: IDC on-premises cluster

Table 9 cluster_label_list

Parameter

Type

Description

key

String

Definition

Key name of the cluster resource tag.

Range

The value can contain 1 to 64 characters.

value

String

Definition

Value of a cluster resource tag.

Range

The value can contain 0 to 128 characters.

Table 10 host_info

Parameter

Type

Description

host_id

String

Definition

Host ID.

Range

The value can contain 1 to 128 characters.

host_name

String

Definition

Host Name

Range

The value can contain 1 to 256 characters.

host_private_ip

String

Definition

Private IP address of the server.

Range

The value can contain 1 to 128 characters.

Example Requests

None

Example Responses

Status code: 200

Request succeeded.

{
  "total_num" : 1,
  "data_list" : [ {
    "id" : "60axxxxx-0xxf-4xx1-be38-5exxxxx1362f",
    "protect_mode" : "alarm",
    "monitor_process" : true,
    "privileged_process_list" : [ "/usr/local/opa" ],
    "privileged_child" : false,
    "protect_directory_info_list" : [ {
      "protect_directory" : "/root/www",
      "exclude_child_directory_list" : [ "/root/www/log" ],
      "exclude_file_list" : [ "/root/www/image/logo.png" ],
      "backup_directory" : "/var/temp/wtp_backup"
    } ],
    "exclude_file_types" : [ "log" ],
    "status" : "not_protect",
    "protected_container_nums" : 14,
    "protected_event_nums" : 5,
    "resource_id" : "21axxxxx-0xxf-2xx1-be67-5exxxxx13783",
    "container_wtp_info" : {
      "image_name" : "registry-cbu.huawei.com/scc_hss_container/hostguard",
      "image_version" : "3.2.22.x86_64",
      "image_type" : "custom",
      "protect_type" : "cluster",
      "cluster_info" : {
        "cluster_id" : "44axxxxx-0xxf-2xx1-9067-5exxxxx13436",
        "cluster_name" : "my-cluster",
        "cluster_version" : "1.18.3",
        "cluster_type" : "cce"
      },
      "cluster_label_list" : [ {
        "key" : "app_name",
        "value" : "test_app"
      } ]
    }
  } ]
}

Status Codes

Status Code

Description

200

Request succeeded.

Error Codes

See Error Codes.