Changing the Status of a Vulnerability
Function
This API is used to change the status of a vulnerability.
Calling Method
For details, see Calling APIs.
URI
PUT /v5/{project_id}/vulnerability/status
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
User ID Minimum: 1 Maximum: 256 |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
enterprise_project_id |
No |
String |
Enterprise user ID. To query all enterprise projects, set this parameter to all_granted_eps. Minimum: 0 Maximum: 128 |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
x-auth-token |
Yes |
String |
iam token Minimum: 32 Maximum: 4096 |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
operate_type |
Yes |
String |
Operation type.
Minimum: 1 Maximum: 64 |
remark |
No |
String |
Remarks Minimum: 0 Maximum: 512 |
select_type |
No |
String |
Select vulnerabilities.
Minimum: 1 Maximum: 64 |
type |
No |
String |
Vulnerability type. The default value is linux_vul. The options are as follows:
Minimum: 0 Maximum: 64 |
data_list |
Yes |
Array of VulOperateInfo objects |
Vulnerability list Array Length: 1 - 500 |
host_data_list |
No |
Array of HostVulOperateInfo objects |
Vulnerability list in the server dimension Array Length: 1 - 500 |
backup_info_id |
No |
String |
Specifies the ID of the backup information processed by the vulnerability. If this parameter is not specified, the backup is not performed. Minimum: 1 Maximum: 128 |
custom_backup_hosts |
No |
Array of custom_backup_hosts objects |
Customize the vault and backup name used by the backup host. For hosts that are not in the list, the system automatically selects the vault with the largest remaining space and generates a backup name. Array Length: 1 - 50 |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
vul_id |
Yes |
String |
Vulnerability ID Minimum: 1 Maximum: 64 |
host_id_list |
Yes |
Array of strings |
Server list Minimum: 1 Maximum: 64 Array Length: 1 - 500 |
Response Parameters
None
Example Requests
Change the vulnerability status of the server whose ID is 71a15ecc-049f-4cca-bd28-5e90aca1817f. Change the status of EulerOS-SA-2021-1894 to ignored.
{ "operate_type" : "ignore", "data_list" : [ { "vul_id" : "EulerOS-SA-2021-1894", "host_id_list" : [ "71a15ecc-049f-4cca-bd28-5e90aca1817f" ] } ] }
Example Responses
None
Status Codes
Status Code |
Description |
---|---|
200 |
successful response |
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.