Domain name for API request: tcss.intl.tencentcloudapi.com.
This API is used to apply the check item level in the "check item + asset" two-level structure.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
| Parameter Name | Required | Type | Description |
|---|---|---|---|
| Action | Yes | String | Common Params. The value used for this API: DescribeCompliancePolicyItemAffectedSummary. |
| Version | Yes | String | Common Params. The value used for this API: 2020-11-01. |
| Region | No | String | Common Params. This parameter is not required. |
| CustomerPolicyItemId | Yes | Integer | CustomerPolicyItemId returned by DescribeComplianceTaskPolicyItemSummaryList, which indicates the check item ID. |
| Parameter Name | Type | Description |
|---|---|---|
| PolicyItemSummary | CompliancePolicyItemSummary | Aggregated information of the assets affected by each check item |
| RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
POST / HTTP/1.1
Host: tcss.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: DescribeCompliancePolicyItemAffectedSummary
<Common request parameters>
{
"CustomerPolicyItemId": 474567
}
{
"Response": {
"PolicyItemSummary": {
"ApplicableVersion": "docker 1.11-1.13, 17.12-20.10.2",
"AssetType": "ASSET_IMAGE",
"AuditProcedure": "Execute the following commands to audit\ndocker ps --quiet | xargs --max-args=1 -I{} docker exec {} cat /proc/1/status | grep '^Uid:' | awk '{print $3}'"
"BasePolicyItemId": 178,
"BenchmarkStandardId": 2,
"BenchmarkStandardName": "CIS Docker",
"Category": "CATEGORY_DOCKER_IMAGES_BUILD_FILE",
"CheckResult": "RESULT_FAILED",
"CheckStatus": "CHECK_FINISHED",
"CustomerPolicyItemId": 5914,
"Description": "When possible, it is best to run container as a non-root user."
"FailedAssetCount": 208,
"FixSuggestion": "Ensure the container image's Dockerfile contains the following instruction: USER <userName or ID>, where the userName or ID refers to a user that can be found in the container base image. If no specific user is created in the container base image, add the useradd command before the USER instruction to create a specific user. For example, to create a user in the Dockerfile: RUN useradd -d /home/username -m -s /bin/bash username USER username Note: If there are users in the image that the container does not need, consider deleting them. After deleting these users, submit the image and generate a new container instance for use."
"IsEnable": 0,
"LastCheckTime": "2024-10-30 02:02:09",
"Name": "Underwrite the user to create and use a container"
"PassedAssetCount": 0,
"RiskLevel": "1",
"WhitelistId": 0
},
"RequestId": "3e8b4c60-58ba-4acc-97fc-33f086c7a3bb"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
| Error Code | Description |
|---|---|
| AuthFailure | A CAM signature/authentication error occurred. |
| FailedOperation | The operation failed. |
| InternalError | An internal error occurred. |
| InvalidParameter | The parameter is incorrect. |
| OperationDenied | The operation was denied. |
| RequestLimitExceeded | The number of requests exceeds the frequency limit. |
文档反馈