All Products
Search
Document Center

Container Registry:ListScanMaliciousFileByTask

Last Updated:Dec 16, 2025

Queries the malicious files of a scan task by page.

Operation description

Before you call this operation, use a Security Center scan engine to scan the image.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • For mandatory resource types, indicate with a prefix of * .
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
cr:ListScanMaliciousFileget
*Instance
acs:cr:{#regionId}:{#accountId}:instance/{#InstanceId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
InstanceIdstringNo

The instance ID.

cri-gu94qynvpwk*****
PageNointegerNo

The page number.

1
PageSizeintegerNo

The number of entries per page. Maximum value: 100. If you specify a value greater than 100 for this parameter, the system reports a parameter error or uses 100 as the maximum value.

30
LevelstringNo

The severity of the malicious file.

High
RepoIdstringNo

The image repository ID.

crr-h1y4l279wb8*****
TagstringNo

The image tag.

V6.11
DigeststringNo

The image digest.

sha256:aa4bffff6406785e930dab1f94c9a1297ba22xxxx71d71504a015764*********
ScanTaskIdstringNo

The ID of the image scan task.

79ee6bc2-3288-4c56-b967-**********

Response parameters

ParameterTypeDescriptionExample
object

Schema of Response

RequestIdstring

The request ID.

52AE49C8-B91A-5C1A-821F-C34324B42F7C
Codeinteger

The return value.

success
PageNointeger

The page number. Default value: 1.

1
IsSuccessboolean

Indicates whether the API request is successful. Valid values:

  • true: successful
  • false: failed
true
PageSizeinteger

The number of entries per page.

30
TotalCountinteger

The total number of entries returned.

13
ScanMaliciousFilesarray<object>

The queried malicious files.

ScanMaliciousFilesobject
ScanTaskIdstring

The ID of the image scan task.

fe2d8980-de45-4f55-b57d-e438e6d2e972
MaliciousNamestring

The type of the malicious file.

Suspected to contain Webshell code
MaliciousMd5string

The MD5 hash value of the malicious file.

e76c9759783cbbc9be0ff91ca3xxxxxx
FirstScanTimelong

The time when the image was first scanned.

2023-04-10 11:42:06
Levelstring

The severity of the malicious file.

remind
FilePathstring

The path of the file.

tenant/0000000000000000/
CreateTimelong

The time when the image was created.

2023-04-10 11:42:06
UpdateTimelong

The time when the image was updated.

2023-04-10 11:42:06

Examples

Sample success responses

JSONformat

{
  "RequestId": "52AE49C8-B91A-5C1A-821F-C34324B42F7C",
  "Code": 0,
  "PageNo": 1,
  "IsSuccess": true,
  "PageSize": 30,
  "TotalCount": 13,
  "ScanMaliciousFiles": [
    {
      "ScanTaskId": "fe2d8980-de45-4f55-b57d-e438e6d2e972",
      "MaliciousName": "Suspected to contain Webshell code",
      "MaliciousMd5": "e76c9759783cbbc9be0ff91ca3xxxxxx",
      "FirstScanTime": 0,
      "Level": "remind",
      "FilePath": "tenant/0000000000000000/",
      "CreateTime": 0,
      "UpdateTime": 0
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history