Querying the Report of a Check Item in a Security Configuration Check
Function
This API is used to query the report of a check item in a security configuration check.
Calling Method
For details, see Calling APIs.
URI
GET /v5/{project_id}/baseline/check-rule/detail
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
User project ID |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
enterprise_project_id |
No |
String |
Enterprise project ID |
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:
|
host_id |
No |
String |
Host ID |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
x-auth-token |
Yes |
String |
User token, which 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 the user token. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
description |
String |
Description |
reference |
String |
Scenario |
audit |
String |
Audit description |
remediation |
String |
Modification suggestion |
check_info_list |
Array of CheckRuleCheckCaseResponseInfo objects |
Test cases |
Example Requests
This API is used to query the report of the configuration check items whose baseline name is SSH, check item ID is 1.12, check standard is cloud security practice standard, and enterprise project ID is xxx.
GET https://{endpoint}/v5/{project_id}/baseline/check-rule/detail?standard=hw_standard&enterprise_project_id=xxx&check_name=SSH&check_type=SSH&check_rule_id=1.12
Example Responses
Status code: 200
Configuration item check report
{"audit":"Run the following commands and verify that ClientAliveInterval is smaller than 300 and ClientAliveCountMax is 3 or less: #grep '^ClientAliveInterval' /etc/ssh/sshd_config ClientAliveInterval 300(default is 0) #grep '^ClientAliveCountMax' /etc/ssh/sshd_config ClientAliveCountMax 0(default is 3)","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 |
Configuration item check report |
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