Update the Security Situation Awareness Configuration Information of a Specific ID
Function
This API is used by an application to update the security situation awareness configuration of a specific ID.
Debugging
You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.
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, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
iotda:securityprofile:update
Write
instance *
-
g:EnterpriseProjectId
-
g:ResourceTag/<tag-key>
-
-
-
URI
PUT /v5/iot/{project_id}/security-profiles/{profile_id}
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Parameter description: project ID. For details, see Obtaining a Project ID. |
|
profile_id |
Yes |
String |
Parameter description: security situation awareness configuration ID, which is allocated by the platform during configuration creation. Value range: The value can contain a maximum of 24 digits and characters. |
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
Instance-Id |
No |
String |
Parameter description: instance ID. This parameter is required only when the API is called from the management plane in the physical multi-tenant scenario. Log in to the IoTDA console and choose Overview in the navigation pane to check the instance ID. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
alarm_level |
No |
String |
Parameter description: severity of a security situation awareness alarm. Constraints: none. Range:
Default value: N/A |
|
security_level |
No |
String |
Parameter description: severity of a security situation awareness item. Constraints: none. Range:
Default value: N/A |
|
enable |
No |
Boolean |
Whether security situation awareness is enabled. |
|
profile |
No |
Array of SecurityProfile objects |
Security situation awareness configuration structure, which is used to deliver device-side detection items to the device. |
|
profile_targets |
No |
SecurityTarget object |
Structure of binding objects for security situation awareness configuration. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
key |
Yes |
String |
Name of the security situation awareness item. |
|
value |
Yes |
Object |
Configuration value of the security situation awareness item. For details about the data format, see the description of the API for creating security situation awareness. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
target_type |
No |
String |
Object bound to the security situation awareness configuration. Currently, only the product level is supported, and only the device-level security situation awareness items take effect. |
|
target_ids |
No |
Array of strings |
List of bound object IDs. When target_type is set to PRODUCT, the product ID can be duplicate in different resource spaces. The value of target_id is in the format of Resource space ID:Product ID. The resource space ID and product ID are combined using a colon (:). |
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
profile_id |
String |
Security situation awareness configuration ID. |
|
security_type |
String |
Security situation awareness configuration type. |
|
alarm_level |
String |
Parameter description: severity of a security situation awareness alarm. Constraints: none. Range:
Default value: N/A |
|
security_level |
String |
Parameter description: severity of a security situation awareness item. Constraints: none. Range:
Default value: N/A |
|
enable |
Boolean |
Whether security situation awareness is enabled. |
|
profile |
Array of SecurityProfile objects |
Security situation awareness configuration structure, which is used to deliver device-side detection items to the device. |
|
profile_targets |
SecurityTarget object |
Structure of binding objects for security situation awareness configuration. |
|
Parameter |
Type |
Description |
|---|---|---|
|
key |
String |
Name of the security situation awareness item. |
|
value |
Object |
Configuration value of the security situation awareness item. For details about the data format, see the description of the API for creating security situation awareness. |
|
Parameter |
Type |
Description |
|---|---|---|
|
target_type |
String |
Object bound to the security situation awareness configuration. Currently, only the product level is supported, and only the device-level security situation awareness items take effect. |
|
target_ids |
Array of strings |
List of bound object IDs. When target_type is set to PRODUCT, the product ID can be duplicate in different resource spaces. The value of target_id is in the format of Resource space ID:Product ID. The resource space ID and product ID are combined using a colon (:). |
Example Requests
PUT https://{endpoint}/v5/iot/{project_id}/security-profiles/{profile_id}
{
"alarm_level" : "CRITICAL",
"security_level" : "BASIC_SECURITY",
"profile" : [ {
"key" : "memory_threshold",
"value" : 80
} ],
"profile_targets" : {
"target_type" : "PRODUCT",
"target_ids" : [ "1d7616926636486cb05120018018cafc:67443bd4ad7db3647deb4f7a" ]
}
}
Example Responses
Status code: 200
OK
{
"profile_id" : "04ed32dc1b0025b52fe3c01a27c2babc",
"security_type" : "DEVICE_MEMORY_CHECK",
"alarm_level" : "CRITICAL",
"security_level" : "BASIC_SECURITY",
"enable" : true,
"profile" : [ {
"key" : "memory_threshold",
"value" : 80
} ],
"profile_targets" : {
"target_type" : "PRODUCT",
"target_ids" : [ "1d7616926636486cb05120018018cafc:67443bd4ad7db3647deb4f7a" ]
}
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
OK |
|
400 |
Bad Request |
|
404 |
Not Found |
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