Obtaining the Policy List
Function
This API is used to obtain the security policy list of all devices in a project.
Calling Method
For details, see Calling APIs.
URI
GET /v1/{project_id}/devices/security-policies
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Project ID. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
limit |
No |
Integer |
Number of records on each page. |
|
name |
No |
String |
Policy name (for filtering). |
|
offset |
No |
Integer |
Pagination offset. |
|
type |
No |
String |
Policy type, which can be GDE (database encryption), GDE_DECRYPT (database decryption), DOM (database O&M), DBSS (DBSS service), DDM (dynamic database masking), or SDM (static database masking). |
Request Parameters
None
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
policy_list |
Array of DevicePolicyDetail objects |
Policy information list. |
|
total |
Long |
Total number of policies. |
|
Parameter |
Type |
Description |
|---|---|---|
|
ddm_config |
DdmConfig object |
Dynamic data masking policy. |
|
ddm_policy_list |
Array of DdmPolicy objects |
array |
|
enabled |
Boolean |
boolean |
|
gde_config |
GdeConfig object |
Database encryption policy. |
|
gde_policy |
GdePolicy object |
Encryption policy. |
|
id |
Long |
Policy ID. |
|
name |
String |
Policy name. |
|
related_datasource_id |
String |
Associated database ID. |
|
related_datasource_name |
String |
Associated database name. |
|
related_datasource_type |
String |
Associated database type. |
|
related_device_id |
String |
ID of the device that executes the policy. |
|
related_device_name |
String |
Name of the device that executes the policy. |
|
related_device_type |
Integer |
Type of the device that executes the policy. |
|
resource |
DeviceResourceInfo object |
Information about resources associated with the security policy on the device. |
|
sdm_config |
SdmConfig object |
Static data masking policy. |
|
sdm_policy_list |
Array of SdmPolicy objects |
array |
|
status |
String |
Policy status. |
|
target_datasource_id |
String |
ID of the target database of the static data masking policy. |
|
target_datasource_name |
String |
Name of the target database of the static data masking policy. |
|
target_datasource_type |
String |
Type of the target database of the static data masking policy. |
|
target_resource |
DeviceResourceInfo object |
Information about resources associated with the security policy on the device. |
|
type |
String |
Policy type. |
|
update_time |
Long |
Update time. |
|
Parameter |
Type |
Description |
|---|---|---|
|
proxy_port |
Integer |
Agent port. |
|
zk_election_port |
Integer |
User-defined ZooKeeper election port, which is available only for big data (HBase and Hive). |
|
zk_port |
Integer |
User-defined ZooKeeper port, which is available only for big data (HBase and Hive). |
|
Parameter |
Type |
Description |
|---|---|---|
|
columns |
Array of Column objects |
Columns configured for the policy. |
|
namespace |
String |
Namespace name. |
|
table |
String |
Table name. |
|
Parameter |
Type |
Description |
|---|---|---|
|
enc_mode |
Integer |
Encryption mode. 1: encryption, 2: decryption. |
|
proxy_port |
Integer |
Agent port. |
|
Parameter |
Type |
Description |
|---|---|---|
|
action |
Integer |
1: encryption, 2: decryption. |
|
alg |
String |
Encryption algorithm, which can be sm4, aes-128, or aes-256. |
|
columns |
Array of Column objects |
Column information to be encrypted. |
|
table |
String |
Table name. |
|
Parameter |
Type |
Description |
|---|---|---|
|
auto_rebuild_target |
Boolean |
Whether to rebuild the table. |
|
clear_target |
Boolean |
Whether to clear the target table. |
|
select_param |
String |
Value of the extraction mode. |
|
select_type |
String |
Extraction type. |
|
skip_dirty_data |
Boolean |
Whether to skip dirty data. |
|
Parameter |
Type |
Description |
|---|---|---|
|
columns |
Array of Column objects |
Column information. |
|
do_mask |
Boolean |
Whether to mask data. |
|
do_move |
Boolean |
Whether to migrate data. |
|
namespace |
String |
Namespace, which is only available for HBase. |
|
table |
String |
Table name. |
|
Parameter |
Type |
Description |
|---|---|---|
|
mask |
Integer |
Masking algorithm name or ID. |
|
name |
String |
Column name. |
|
Parameter |
Type |
Description |
|---|---|---|
|
account |
String |
Username. |
|
address |
String |
Address. |
|
address_type |
String |
Address type (IPv4 or IPv6). |
|
case_sensitive |
Boolean |
\ |
|
database_name |
String |
Database name. |
|
extra_params |
String |
Reserved field. |
|
password |
String |
Password. |
|
port |
Integer |
Port. |
|
res_id |
String |
Database ID. |
|
res_type |
String |
Database type. |
|
res_version |
String |
Database version. |
Example Requests
None
Example Responses
None
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Query result. |
|
401 |
Unauthorized. The user is not logged in or the token is invalid. |
|
403 |
Unauthorized to access the resource. |
|
404 |
The specified project does not exist. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot