All Products
Search
Document Center

Security Center:ListDetectionRules

Last Updated:Dec 08, 2025

Retrieves a list of detection rules.

Operation description

Notifications are subject to frequency and time limits. Each user can receive a maximum of two notifications per day. These notifications are sent only between 08:00 and 20:00.

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-sas:ListDetectionRules

list

*DetectionRule

acs:yundun-sas::{#accountId}:detection/*

None None

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

No

The region where the Data Management center of threat analysis is located. Select a region based on the region where your assets are located. Valid values:

  • cn-hangzhou: Your assets are in the Chinese mainland.

  • ap-southeast-1: Your assets are outside China.

cn-hangzhou

Lang

string

No

The language of the response. Valid values:

  • zh (default): Chinese.

  • en: English.

zh

DetectionRuleName

string

No

The name of the detection rule.

Detect Discovery Behavior for Local Systems Groups

DetectionRuleId

string

No

The ID of the detection rule.

dr-ppa85gfw69tgwkys****

DetectionRuleIds

array

No

The list of detection rule IDs.

string

No

The ID of the detection rule.

dr-ppa85gfw69tgwkys****

DetectionRuleType

string

No

The type of the detection rule. Valid values:

  • preset: a built-in detection rule.

  • custom: a custom detection rule.

  • custom_template: a rule template.

preset

DetectionRuleStatus

string

No

The status of the detection rule.

enabled

AlertType

string

No

The alert type.

siem_rule_type_alert_storm

AlertLevel

string

No

The threat level of the alert. Valid values:

  • 5: critical.

  • 4: important.

  • 3: medium.

  • 2: low.

  • 1: informational.

1

AlertTacticId

string

No

The alert tactic phase.

TA0042

AlertAttCk

string

No

The ATT&CK technique of the alert.

Discovery

IncidentAggregationType

string

No

The event aggregation type. Valid values:

  • none: No events are generated.

  • graph_compute: graph computing (supported by predefined rules).

  • expert: expert rule.

  • passthrough: alert passthrough (one-to-one).

  • window: aggregation of similar alerts (by window).

graph_compute

LogCategoryId

string

No

The ID of the log normalization category.

NETWORK_CATEGORY

LogSchemaId

string

No

The ID of the log normalization schema.

API_RISK_ACTIVITY

DetectionExpressionType

string

No

The type of the detection rule expression.

playbook

OrderFieldName

string

No

The field to sort by. Valid values:

  • GmtCreate: the creation time.

  • GmtModified: the update time.

GmtModified

OrderDirection

string

No

The sort order. Valid values:

  • asc: ascending order. This is the default value.

  • desc: descending order.

asc

PageNumber

integer

No

The pagination parameter. This specifies the current page number.

1

PageSize

integer

No

The pagination parameter. This specifies the number of entries per page.

100

RoleFor

integer

No

The user ID that the administrator uses to switch to the perspective of another member.

113091674488****

MaxResults

integer

No

The maximum number of data entries to read.

50

NextToken

string

No

The token that is used to start the next query.

AAAAAUqcj6VO4E3ECWIrFczs****

Response elements

Element

Type

Description

Example

object

The response body.

RequestId

string

The request ID.

508DCFFD-4508-54BF-A8A0-E97A0FA6****

DetectionRules

array<object>

The list of detection rules.

array<object>

The detection rule.

CreateTime

integer

The creation time.

2023-03-21 13:47:01

UpdateTime

integer

The update time.

2023-04-16 10:51:00

DetectionRuleId

string

The ID of the detection rule.

jndi-attack-success_http_netstat

DetectionRuleName

string

The name of the detection rule.

Detect Discovery Behavior for Local Systems Groups

DetectionRuleDescription

string

The description of the detection rule.

Check the enumeration behavior of local system groups. An attacker may attempt to find the Local Systems group and its permission settings.

DetectionRuleType

string

The type of the detection rule. Valid values:

  • preset: a built-in detection rule.

  • custom: a custom detection rule.

  • custom_template: a rule template.

custom

DetectionRuleStatus

string

The status of the detection rule. Valid values:

  • enabled: The rule is enabled.

  • disabled: The rule is disabled.

  • testing: The rule is being tested.

enabled

DetectionExpressionType

string

The type of the detection rule expression.

playbook

DetectionExpressionContent

string

The content of the detection rule expression.

*|set session mode=scan;SELECT * FROM log WHERE schema = 'PROCESS_START_ACTIVITY' AND ( proc_path LIKE '%/groups' OR ( ( proc_path LIKE '%/cat' OR proc_path LIKE '%/head' OR proc_path LIKE '%/tail' OR proc_path LIKE '%/more' ) AND cmdline LIKE '%/etc/group%' ) )

LogCategoryId

string

The ID of the log normalization category.

NETWORK_CATEGORY

LogSchemaId

string

The ID of the log normalization schema.

API_RISK_ACTIVITY

AlertSchemaId

string

The ID of the alert template for the detection rule. Valid values:

  • ALERT_ACTIVITY: other alerts.

  • EDR_ALERT_ACTIVITY: Endpoint Detection and Response (EDR) alerts.

  • FIREWALL_ALERT_ACTIVITY: firewall alerts.

  • WAF_ALERT_ACTIVITY: Web Application Firewall (WAF) alerts.

ALERT_ACTIVITY

ScheduleType

string

The scheduling type. Valid values:

  • fixed_rate: fixed interval

  • cron: cron expression

fixed_rate

ScheduleExpression

string

The cron expression for scheduling. This parameter is required when ScheduleType is set to cron.

5m

ScheduleMaxRetries

integer

The maximum number of retries after a timeout. The value can be from 1 to 100.

1

ScheduleBeginTime

integer

The start time of the scheduling. This is a 13-digit timestamp.

1733269771123

ScheduleWindow

string

The length of the scheduling window.

5m

ScheduleMaxTimeout

integer

The maximum timeout period, in seconds. The value can be from 60 to 1800.

60

AlertType

string

The alert type.

WebShell

AlertLevel

string

The threat level of the alert. Valid values:

  • 5: critical.

  • 4: important.

  • 3: medium.

  • 2: low.

  • 1: informational.

1

AlertTacticId

string

The alert tactic phase.

TA0042

AlertAttCk

string

The ATT&CK technique of the alert.

Discovery

AlertThresholdPeriod

string

The length of the alert threshold period.

5m

AlertThresholdCount

integer

The number of alert thresholds.

10

AlertThresholdGroup

string

The list of alert threshold fields, separated by commas.

alert_type,ip

IncidentAggregationType

string

The event aggregation type. Valid values:

  • none: No events are generated.

  • graph_compute: graph computing (supported by predefined rules).

  • expert: expert rule.

  • passthrough: alert passthrough (one-to-one).

  • window: aggregation of similar alerts (by window).

passthrough

IncidentAggregationExpression

string

The configuration of the event aggregation period.

5m

PlaybookUuid

string

The UUID of the playbook.

dde983ed-eb56-45ea-ac2e-3b12b2a9****

PlaybookParameters

string

The custom parameters of the playbook.

{ "ip": { "ip": "124.23.*.*" } }

Playbook

object

The configuration of the playbook.

Flow

string

The flow configuration of the playbook.

[ { "id": "EndEvent_1fqpq4h", "zIndex": 1, "data": { "nodeType": "endEvent", "appType": "basic", "valueData": { }, "icon": "icon-radio-off-full" }, "position": { "x": 1369, "y": 174 } } ]

Config

string

The configuration of the input parameters for invoking the playbook.

[ { "name": "expireDay", "dataType": "Integer", "required": true, "isArray": false, "example": "7", "description": "desc", "typeName": "Integer", "dataClass": "normal", "stanchDefaultValue": "7" } ]

EntityMappings

array<object>

The entity mapping configuration.

array<object>

The entity mapping configuration.

NormalizationSchemaId

string

The entity type ID.

ip

NormalizationFieldMappings

array<object>

The entity mapping configuration.

object

The entity mapping configuration.

NormalizationFieldName

string

The standard entity field.

src_ip

MappingFieldName

string

The mapped field.

ip

NormalizationFieldType

string

The data type of the standard entity field.

vachar

AlertName

string

The alert name. You can use $$ to reference the output fields of the query.

Detected high-frequency multi-type network attacks from $src_ip$

AlertDescription

string

The alert description. You can use $$ to reference the output fields of the query.

Alert from: $product_code$, detected network attack from $src_ip$, affected assets include: $dst_ip$

PageNumber

integer

The pagination parameter. This specifies the current page number.

2

PageSize

integer

The pagination parameter. This specifies the number of entries per page.

10

TotalCount

integer

The total number of records.

6

MaxResults

integer

The maximum number of data entries to read.

50

NextToken

string

The token that is used to start the next query.

AAAAAUqcj6VO4E3ECWIrFczs****

Examples

Success response

JSON format

{
  "RequestId": "508DCFFD-4508-54BF-A8A0-E97A0FA6****",
  "DetectionRules": [
    {
      "CreateTime": 0,
      "UpdateTime": 0,
      "DetectionRuleId": "jndi-attack-success_http_netstat",
      "DetectionRuleName": "Detect Discovery Behavior for Local Systems Groups\n",
      "DetectionRuleDescription": "Check the enumeration behavior of local system groups. An attacker may attempt to find the Local Systems group and its permission settings.",
      "DetectionRuleType": "custom",
      "DetectionRuleStatus": "enabled",
      "DetectionExpressionType": "playbook",
      "DetectionExpressionContent": "*|set session mode=scan;SELECT * FROM log\nWHERE schema = 'PROCESS_START_ACTIVITY'\nAND (\n    proc_path LIKE '%/groups'\n    OR (\n        (\n            proc_path LIKE '%/cat'\n            OR proc_path LIKE '%/head'\n            OR proc_path LIKE '%/tail'\n            OR proc_path LIKE '%/more'\n        )\n        AND cmdline LIKE '%/etc/group%'\n    )\n)",
      "LogCategoryId": "NETWORK_CATEGORY",
      "LogSchemaId": "API_RISK_ACTIVITY",
      "AlertSchemaId": "ALERT_ACTIVITY",
      "ScheduleType": "fixed_rate",
      "ScheduleExpression": "5m",
      "ScheduleMaxRetries": 1,
      "ScheduleBeginTime": 1733269771123,
      "ScheduleWindow": "5m",
      "ScheduleMaxTimeout": 60,
      "AlertType": "WebShell",
      "AlertLevel": "1",
      "AlertTacticId": "TA0042",
      "AlertAttCk": "Discovery",
      "AlertThresholdPeriod": "5m",
      "AlertThresholdCount": 10,
      "AlertThresholdGroup": "alert_type,ip",
      "IncidentAggregationType": "passthrough",
      "IncidentAggregationExpression": "5m",
      "PlaybookUuid": "dde983ed-eb56-45ea-ac2e-3b12b2a9****",
      "PlaybookParameters": "{\n    \"ip\": {\n        \"ip\": \"124.23.*.*\"\n    }\n}",
      "Playbook": {
        "Flow": "[\n    {\n        \"id\": \"EndEvent_1fqpq4h\",\n        \"zIndex\": 1,\n        \"data\": {\n            \"nodeType\": \"endEvent\",\n            \"appType\": \"basic\",\n            \"valueData\": {\n\n            },\n            \"icon\": \"icon-radio-off-full\"\n        },\n        \"position\": {\n            \"x\": 1369,\n            \"y\": 174\n        }\n    }\n]",
        "Config": "[\n    {\n        \"name\": \"expireDay\",\n        \"dataType\": \"Integer\",\n        \"required\": true,\n        \"isArray\": false,\n        \"example\": \"7\",\n        \"description\": \"desc\",\n        \"typeName\": \"Integer\",\n        \"dataClass\": \"normal\",\n        \"stanchDefaultValue\": \"7\"\n    }\n]"
      },
      "EntityMappings": [
        {
          "NormalizationSchemaId": "ip",
          "NormalizationFieldMappings": [
            {
              "NormalizationFieldName": "src_ip",
              "MappingFieldName": "ip",
              "NormalizationFieldType": "vachar"
            }
          ]
        }
      ],
      "AlertName": "Detected high-frequency multi-type network attacks from $src_ip$",
      "AlertDescription": "Alert from: $product_code$, detected network attack from $src_ip$, affected assets include: $dst_ip$"
    }
  ],
  "PageNumber": 2,
  "PageSize": 10,
  "TotalCount": 6,
  "MaxResults": 50,
  "NextToken": "AAAAAUqcj6VO4E3ECWIrFczs****"
}

Error codes

HTTP status code

Error code

Error message

Description

400 IdempotentParameterMismatch The request uses the same client token as a previous, but non-identical request. Do not reuse a client token with different requests, unless the requests are identical.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.