Creates an alert handling rule for image security events.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
yundun-sas:AddImageEventOperation |
create |
*ImageEventOperation
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| EventType |
string |
Yes |
The alert type.
|
sensitiveFile |
| OperationCode |
string |
Yes |
The operation code.
|
whitelist |
| Conditions |
string |
Yes |
The rule conditions in JSON format. Valid values of keys:
|
[{\"condition\": \"MD5\", \"type\": \"equals\", \"value\": \"0083a31cc0083a31ccf7c10367a6e783e\"}] |
| Scenarios |
string |
No |
The application scope of the rule in JSON format. Valid values of keys:
|
{\"type\": \"repo\", \"value\": \"test-aaa/shenzhen-repo-01\"} |
| EventKey |
string |
No |
The keyword of the alert item. |
PEM |
| EventName |
string |
No |
The name of the alert item. |
PEM |
| Source |
string |
No |
The source of the whitelist. Valid values:
|
agentless |
| Note |
string |
No |
The remarks to add. |
test |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response parameters. |
||
| Data |
object |
The returned data. |
|
| Id |
integer |
The primary key of the alert handling rule. |
443496 |
| EventType |
string |
The alert type.
|
sensitiveFile |
| OperationCode |
string |
The operation code.
|
whitelist |
| Conditions |
string |
The rule conditions in JSON format. Valid values of keys:
|
[{\"condition\": \"MD5\", \"type\": \"equals\", \"value\": \"0083a31cc0083a31ccf7c10367a6e783e\"}] |
| Scenarios |
string |
The application scope of the rule in JSON format. Valid values of keys:
|
{\"type\": \"repo\", \"value\": \"test-aaa/shenzhen-repo-01\"} |
| EventKey |
string |
The keyword of the alert item. |
PEM |
| EventName |
string |
The name of the alert item. |
PEM |
| Success |
boolean |
Indicates whether the request was successful. Valid values:
|
true |
| Code |
string |
The HTTP status code. |
200 |
| Message |
string |
The response message. |
successful |
| RequestId |
string |
The request ID. |
0C8487EF-50C2-54BB-8634-10F8C35D**** |
Examples
Success response
JSON format
{
"Data": {
"Id": 443496,
"EventType": "sensitiveFile",
"OperationCode": "whitelist",
"Conditions": "[{\\\"condition\\\": \\\"MD5\\\", \\\"type\\\": \\\"equals\\\", \\\"value\\\": \\\"0083a31cc0083a31ccf7c10367a6e783e\\\"}]\n",
"Scenarios": "{\\\"type\\\": \\\"repo\\\", \\\"value\\\": \\\"test-aaa/shenzhen-repo-01\\\"}\n",
"EventKey": "PEM",
"EventName": "PEM"
},
"Success": true,
"Code": "200",
"Message": "successful",
"RequestId": "0C8487EF-50C2-54BB-8634-10F8C35D****"
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 500 | ServerError | ServerError | |
| 403 | NoPermission | caller has no permission | You are not authorized to do this operation. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.