DescribeRiskEventGroup

Updated at:

Queries the detailed data of intrusion prevention events.

Operation description

This operation queries and downloads detailed data of intrusion prevention events. Query 5 to 10 entries at a time. To prevent query timeouts, set the NoLocation parameter to true if you do not need to return IP geolocation information.

QPS limit

The QPS limit for a single user is 10 queries per second. If the limit is exceeded, API calls are throttled, which may affect your business. Call the API at a reasonable frequency.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

yundun-cloudfirewall:DescribeRiskEventGroup

list

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

Lang

string

No

The language of the request and response. Valid values:

  • zh (default): Chinese.

  • en: English.

zh

StartTime

string

Yes

The start time of the query. The value is a UNIX timestamp in seconds.

1534408189

EndTime

string

Yes

The end time of the query. The value is a UNIX timestamp in seconds.

1534408267

Direction

string

No

The traffic direction of the intrusion prevention events. Valid values:

  • in: inbound.

  • out: outbound.

Note

If you do not specify this parameter, events in all traffic directions are queried.

in

PageSize

string

No

The paging Settings for the number of entries to return on each page in a paged query.

Default value: 6, which indicates that 6 entries are returned on each page. Maximum value: 10.

6

CurrentPage

string

No

The paging Settings that specify which page of data to return in a paged query. Default value: 1, which indicates that the first page is returned.

1

DataType

string

Yes

The risk event type. Valid values:

  • session: intrusion prevention events. This is the only valid value.

session

RuleSource

string

No

The source of the detection rule for the intrusion prevention events. Valid values:

  • 1: basic protection.

  • 2: virtual patches.

  • 4: threat intelligence.

Note

If you do not specify this parameter, events from all rule sources are queried.

1

RuleResult

string

No

The defense status of Cloud Firewall. Valid values:

  • 1: alert.

  • 2: block.

Note

If you do not specify this parameter, events in all defense statuses are queried.

1

SrcIP

string

No

The source IP address that you want to query. If you specify this parameter, intrusion prevention events that involve this source IP address are queried.

192.0.XX.XX

DstIP

string

No

The destination IP address that you want to query. If you specify this parameter, intrusion prevention events that involve this destination IP address are queried.

192.0.XX.XX

VulLevel

string

No

The security level of the intrusion prevention events. Valid values:

  • 1: low risk.

  • 2: medium risk.

  • 3: high risk.

Note

If you do not specify this parameter, events at all security levels are queried.

1

FirewallType

string

No

The type of the cloud firewall. Valid values:

  • VpcFirewall: virtual private cloud (VPC) firewalls.

  • InternetFirewall (default): the Internet Border firewall.

InternetFirewall

SrcNetworkInstanceId

string

No

The instance ID of the source VPC-connected instance.

Note

You only need to configure the Settings for this parameter when FirewallType is set to VpcFirewall.

vpc-uf6e9a9zyokj2ywuo****

DstNetworkInstanceId

string

No

The instance ID of the destination VPC-connected instance.

Note

You only need to configure the Settings for this parameter when FirewallType is set to VpcFirewall.

vpc-uf6e9a9zyokj2ywuo****

AttackType

string

No

The attack type of the intrusion prevention events. Valid values:

  • 1: abnormal connection.

  • 2: commands to execute.

  • 3: brute-force attacks.

  • 4: scan.

  • 5: other.

  • 6: information leak.

  • 7: DoS attack.

  • 8: buffer overflow attack.

  • 9: web attack.

  • 10: trojan backdoor.

  • 11: virus or worm.

  • 12: mining behavior.

  • 13: reverse shell.

Note

If you do not configure the Settings for this parameter, events of all attack types are queried.

1

NoLocation

string

No

Specifies whether to query the geolocation information of IP addresses. Valid values:

  • true: does not query the geolocation information of IP addresses.

  • false (default): queries the geolocation information of IP addresses.

false

AttackApp

array

No

The names of the attacked applications. Specify the value in the ["AttackApp1","AttackApp2"] format.

["MySql","DNS"]

string

No

The names of the attacked applications. Specify the value in the ["AttackApp1","AttackApp2"] format.

Redis

BuyVersion

integer

No

The purchased edition. Valid values:

  • 2: Premium Edition.

  • 3: Enterprise Edition.

  • 4: Ultimate Edition.

  • 10: Pay-as-you-go Edition.

10

Sort

string

No

The field based on which the results are sorted. Valid values:

  • VulLevel (default): sorts the results based on the risk level.

  • LastTime: sorts the results based on the time when the event last occurred.

LastTime

Order

string

No

The sort order. Valid values:

  • asc: ascending order.

  • desc (default): descending order.

desc

EventName

string

No

The name of the intrusion prevention event.

wooden horse rear door communication

IsOnlyPrivateAssoc

string

No

Specifies whether to query only the data for which private network tracing is completed.

true

AttackAppCategory

array

No

The categories of the attacked applications. Specify the value in the ["AttackAppCategory1","AttackAppCategory2"] format.

string

No

The categories of the attacked applications. Specify the value in the ["AttackAppCategory1","AttackAppCategory2"] format.

AI Component

When you call this API operation, you must add the common request parameters of Alibaba Cloud API in addition to the request parameters described in this topic. For more information about common request parameters, see Common parameters. For more information about the request format of this API operation, see the Examples section in this topic.

Response elements

Element

Type

Description

Example

object

The detailed data of intrusion prevention events.

TotalCount

integer

The total number of risk events.

20

RequestId

string

The ID of the request.

B14757D0-4640-4B44-AC67-7F558FE7E6EF

DataList

array<object>

The list of returned data.

array<object>

The list of returned data.

Direction

string

The traffic direction of the intrusion prevention event. Valid values:

  • in: Inbound.

  • out: Outbound.

in

EventName

string

The name of the intrusion prevention event.

Web Directory Traversal Attack

DstIP

string

The queried destination IP address. This indicates that the intrusion prevention event includes this destination IP address.

192.0.XX.XX

AttackType

integer

The attack type of the intrusion prevention event. Valid values:

  • 1: Abnormal connection.

  • 2: Command execute.

  • 3: Brute-force attacks.

  • 4: Scan.

  • 5: Other.

  • 6: Information leak.

  • 7: DoS attack.

  • 8: Overflow attack.

  • 9: Web attack.

  • 10: Trojan backdoor.

  • 11: Virus and worm.

  • 12: Mining behavior.

  • 13: Reverse shell.

1

Tag

string

The intelligence tags label for critical event protection.

test-tag

RuleId

string

The ID of the protection rule for the intrusion prevention event.

1000****

EventId

string

The ID of the intrusion prevention event.

2b58efae-4c4b-4d96-9544-a586fb1f****

ResourceType

string

The public IP address type of the intrusion prevention event. Valid values:

  • EIP: Elastic IP address.

  • EcsPublicIP: Public IP addresses of Elastic Compute Service (ECS) instances.

  • EcsEIP: EIP of an ECS instance.

  • NatPublicIP: Public IP address of a NAT gateway.

  • NatEIP: EIP of a NAT gateway.

  • SlbPublicIp: Public IP address of an SLB instance.

EcsPublicIP

FirstEventTime

integer

The time when the intrusion event first occurred. The value is a UNIX timestamp accurate to seconds.

1534408189

Description

string

The description of the intrusion prevention event.

A directory traversal attack was detected in Web access for HTTP requests

EventCount

integer

The number of intrusion prevention events.

100

VulLevel

integer

The security level of the intrusion prevention event. Valid values:

  • 1: Low.

  • 2: Medium.

  • 3: High.

1

AttackApp

string

The name of the attacked application.

MySql

RuleSource

integer

The source of the detection rule for the intrusion prevention event. Valid values:

  • 1: Basic protection.

  • 2: Virtual patches.

  • 4: Threat intelligence.

1

RuleResult

integer

The defense status. Valid values:

  • 1: Alert.

  • 2: Block.

2

SrcIP

string

The queried source IP address. This indicates that the intrusion prevention event includes this source IP address.

192.0.XX.XX

LastEventTime

integer

The time when the intrusion prevention event last occurred. The value is a UNIX timestamp accurate to seconds.

1534408267

ResourcePrivateIPList

array<object>

The private IP address information of the intrusion prevention event. This information is returned as an array of RegionNo, ResourceInstanceId, ResourceInstanceName, and ResourcePrivateIP.
RegionNo indicates the region ID to which the IP address belongs. ResourceInstanceId indicates the instance ID to which the IP address belongs. ResourceInstanceName indicates the name of the instance to which the IP address belongs. ResourcePrivateIP indicates the IP address.

object

The private IP address information of the intrusion prevention event. This information is returned as an array of RegionNo, ResourceInstanceId, ResourceInstanceName, and ResourcePrivateIP.
RegionNo indicates the region ID to which the IP address belongs. ResourceInstanceId indicates the instance ID to which the IP address belongs. ResourceInstanceName indicates the name of the instance to which the IP address belongs. ResourcePrivateIP indicates the IP address.

ResourceInstanceName

string

The instance name.

LD-shenzhen-zy****

ResourcePrivateIP

string

The private IP address.

10.255.XX.XX

ResourceInstanceId

string

The instance ID.

i-wz92jf4scg2zb74p****

RegionNo

string

The region ID. This indicates the region ID to which the private IP address belongs.

cn-hangzhou

SrcPrivateIPList

array

The list of source private IP addresses for the intrusion prevention event.

string

The list of source private IP addresses for the intrusion prevention event.

Note

This parameter is returned only for outbound traffic.

["192.168.XX.XX","192.168.XX.XX"]

VpcSrcInfo

object

The source VPC information of the intrusion prevention event. This structure contains the EcsInstanceId, EcsInstanceName, NetworkInstanceId, NetworkInstanceName, and RegionNo parameters.
EcsInstanceId indicates the ECS instance ID in the VPC. EcsInstanceName indicates the name of the ECS instance in the VPC. NetworkInstanceId indicates the VPC-connected instance ID. NetworkInstanceName indicates the VPC-connected instance name. RegionNo indicates the region ID to which the VPC-connected instance belongs.

EcsInstanceName

string

The name of the ECS instance.

LD-shenzhen-zy****

NetworkInstanceName

string

The VPC-connected instance name.

VPC-SH-TX****

NetworkInstanceId

string

The VPC-connected instance ID.

vpc-uf6e9a9zyokj2ywuo****

EcsInstanceId

string

The ECS instance ID.

i-wz92jf4scg2zb74p****

RegionNo

string

The region ID. This indicates the region ID to which the source VPC-connected instance belongs.

cn-hangzhou

VpcDstInfo

object

The destination VPC information of the intrusion prevention event. This structure contains the EcsInstanceId, EcsInstanceName, NetworkInstanceId, NetworkInstanceName, and RegionNo parameters.
EcsInstanceId indicates the ECS instance ID in the VPC. EcsInstanceName indicates the name of the ECS instance in the VPC. NetworkInstanceId indicates the VPC-connected instance ID. NetworkInstanceName indicates the VPC-connected instance name. RegionNo indicates the region ID to which the VPC-connected instance belongs.

EcsInstanceName

string

The name of the ECS instance.

LD-shenzhen-zy****

NetworkInstanceName

string

The VPC-connected instance name.

VPC-SH-TX****

NetworkInstanceId

string

The VPC-connected instance ID.

vpc-uf6e9a9zyokj2ywuo****

EcsInstanceId

string

The ECS instance ID.

i-wz92jf4scg2zb74p****

RegionNo

string

The region ID. This indicates the region ID to which the destination VPC-connected instance belongs.

cn-hangzhou

IPLocationInfo

object

The IP geolocation information. This struct contains the CityId, CityName, CountryId, and CountryName parameters.
CityId indicates the ID of the city to which the IP address belongs. CityName indicates the name of the city to which the IP address belongs. CountryId indicates the ID of the country to which the IP address belongs. CountryName indicates the name of the country to which the IP address belongs.

CityId

string

The city ID.

510100

CountryName

string

The country name.

China

CityName

string

The city name.

Chengdu

CountryId

string

The country ID.

CN

SrcIPTag deprecated

string

The source IP address label, which provides the identity of whether the IP address is one of the back-to-origin IP addresses of a cloud service.

WAF Back-to-origin Address

SrcIPTags

array

The list of IP address tags.

string

The IP address tag.

Anti-DDoS Back-to-origin Address

HitType

string

The type of threat intelligence matched by the event. Valid values: ip, domain, and url. This parameter is returned only for events from the threat intelligence source and is empty for other sources.

domain

HitContent

string

The specific threat intelligence value matched by the event, such as an IP address, domain name, or URL. This parameter is returned only for events from the threat intelligence source and is empty for other sources.

www.example.com

Examples

Success response

JSON format

{
  "TotalCount": 20,
  "RequestId": "B14757D0-4640-4B44-AC67-7F558FE7E6EF",
  "DataList": [
    {
      "Direction": "in",
      "EventName": "Web Directory Traversal Attack",
      "DstIP": "192.0.XX.XX",
      "AttackType": 1,
      "Tag": "test-tag",
      "RuleId": "1000****",
      "EventId": "2b58efae-4c4b-4d96-9544-a586fb1f****",
      "ResourceType": "EcsPublicIP",
      "FirstEventTime": 1534408189,
      "Description": "A directory traversal attack was detected in Web access for HTTP requests",
      "EventCount": 100,
      "VulLevel": 1,
      "AttackApp": "MySql",
      "RuleSource": 1,
      "RuleResult": 2,
      "SrcIP": "192.0.XX.XX",
      "LastEventTime": 1534408267,
      "ResourcePrivateIPList": [
        {
          "ResourceInstanceName": "LD-shenzhen-zy****",
          "ResourcePrivateIP": "10.255.XX.XX",
          "ResourceInstanceId": "i-wz92jf4scg2zb74p****",
          "RegionNo": "cn-hangzhou"
        }
      ],
      "SrcPrivateIPList": [
        "[\"192.168.XX.XX\",\"192.168.XX.XX\"]"
      ],
      "VpcSrcInfo": {
        "EcsInstanceName": "LD-shenzhen-zy****",
        "NetworkInstanceName": "VPC-SH-TX****",
        "NetworkInstanceId": "vpc-uf6e9a9zyokj2ywuo****",
        "EcsInstanceId": "i-wz92jf4scg2zb74p****",
        "RegionNo": "cn-hangzhou"
      },
      "VpcDstInfo": {
        "EcsInstanceName": "LD-shenzhen-zy****",
        "NetworkInstanceName": "VPC-SH-TX****",
        "NetworkInstanceId": "vpc-uf6e9a9zyokj2ywuo****",
        "EcsInstanceId": "i-wz92jf4scg2zb74p****",
        "RegionNo": "cn-hangzhou"
      },
      "IPLocationInfo": {
        "CityId": "510100",
        "CountryName": "China",
        "CityName": "Chengdu",
        "CountryId": "CN"
      },
      "SrcIPTag": "WAF Back-to-origin Address",
      "SrcIPTags": [
        "Anti-DDoS Back-to-origin Address"
      ],
      "HitType": "domain",
      "HitContent": "www.example.com"
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

400 ErrorAliUid Aliuid invalid. The aliuid is invalid.
400 ErrorFirewallType The specified firewall type is invalid. The firewall type of traffic log is invalid.
400 ErrorParameters A parameter error occurred. A parameter error occurred.
400 ErrorDirectionError The direction is invalid. The direction is invalid.
400 ErrorIpFormat The IP address is invalid. The IP address is invalid.
400 ErrorRuleSourceError The rule source is invalid. The rule source is invalid.
400 ErrorRuleResultError The rule result is invalid. The rule result is invalid.
400 ErrorVulLevelFailed VulLevel has failed. VulLevel has failed.
400 ErrorTimeError time range invalid. The specified time is invalid. Select again.
400 ErrorIntervalError The interval is invalid. The interval is invalid.
400 ErrorPageNo Either page number or page size is invalid. Either page number or page size is invalid.
400 ErrorDBSelectError A database select error occurred. The error message returned because an internal error has occurred in querying the database.
400 ErrorMarshalJSON internal error. Internal error.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.