Querying the Mirror Configuration Check Report
Function
This API is used to query the mirror configuration check report.
Calling Method
For details, see Calling APIs.
URI
GET /v5/{project_id}/image/baseline/check-rule/detail
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Tenant project ID |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
enterprise_project_id |
No |
String |
Enterprise project ID. To query all enterprise projects, set this parameter to all_granted_eps. |
image_type |
Yes |
String |
Image type. The options are as follows:
|
namespace |
No |
String |
Specifies the organization name. If no image information is available, all images are queried. |
image_name |
No |
String |
Image name |
image_version |
No |
String |
Image tag name |
check_name |
Yes |
String |
Baseline name |
check_type |
Yes |
String |
Baseline Type |
check_rule_id |
Yes |
String |
Check item ID |
standard |
Yes |
String |
Standard type. Its value can be:
|
instance_id |
No |
String |
Enterprise repository instance ID. This API is not required for SWR shared edition. |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
x-auth-token |
Yes |
String |
User token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is a token. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
description |
String |
Check item description |
reference |
String |
Reference |
audit |
String |
Audit description |
remediation |
String |
Suggestion |
check_info_list |
Array of ImageCheckRuleCheckCaseResponseInfo objects |
Test case |
Example Requests
Query the check report of the configuration item whose organization is aaa, image name is centos7, image version is common, baseline name is SSH, check item ID is 1.12, and standard type is cloud standard.
GET https://{endpoint}/v5/{project_id}/image/baseline/check-rule/detail?image_type=private_image&namespace=aaa&image_name=centos7&image_version=common&check_rule_id=1.12&standard=hw_standard&check_type=SSH&check_name=SSH&enterprise_project_id=all_granted_eps
Example Responses
Status code: 200
The check report of configuration check items is returned.
{"audit":"Check the configuration file: /etc/pam.d/system","check_info_list":[{"check_description":"Check the configuration file: /etc/pam.d/system-auth"},{"current_value":""},{"suggest_value":"auth required is configured for each file."}],"description":"The two options ClientAliveInterval and ClientAliveCountMax control the timeout of SSH sessions. The ClientAliveInterval parameter sets a timeout interval in seconds after which if no data has been received from the client, sshd will send a message through the encrypted channel to request a response from the client. The ClientAliveCountMax parameter sets the number of client alive messages which may be sent without sshd receiving any messages back from the client. For example, if the ClientAliveInterval is set to 15s and the ClientAliveCountMax is set to 3, unresponsive SSH clients will be disconnected after approximately 45s.","reference":"","remediation":"Edit the /etc/ssh/sshd_config file to set the parameter as follows: ClientAliveInterval 300 ClientAliveCountMax 0"}
Status Codes
Status Code |
Description |
---|---|
200 |
The check report of configuration check items is returned. |
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