MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Collection |
Rule body
id: 1dd1d9e5-3ebf-43cb-be07-6082d5eabe79
name: Snowflake - Unusual query
description: |
'Detects unusual query.'
severity: Medium
status: Available
requiredDataConnectors:
- connectorId: Snowflake
dataTypes:
- Snowflake
queryFrequency: 1h
queryPeriod: 1h
triggerOperator: gt
triggerThreshold: 0
tactics:
- Collection
relevantTechniques:
- T1119
query: |
Snowflake
| where QueryType =~ 'SELECT'
| where QueryExecutionStatus =~ 'SUCCESS'
| where QueryText startswith @'SELECT *'
| extend AccountCustomEntity = TargetUsername
entityMappings:
- entityType: Account
fieldMappings:
- identifier: Name
columnName: AccountCustomEntity
version: 1.0.1
kind: Scheduled
Stages and Predicates
Stage 1: source
Snowflake
Stage 2: where
| where QueryType =~ 'SELECT'
Stage 3: where
| where QueryExecutionStatus =~ 'SUCCESS'
Stage 4: where
| where QueryText startswith @'SELECT *'
Stage 5: extend
| extend AccountCustomEntity = TargetUsername
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
QueryExecutionStatus | eq |
| field:"QueryExecutionStatus" kind:eq value:"SUCCESS" |
QueryText | starts_with |
| field:"QueryText" kind:starts_with value:"SELECT *" |
QueryType | eq |
| field:"QueryType" kind:eq value:"SELECT" |
Output fields
These fields are emitted when the rule matches.
| Field | Source |
|---|---|
AccountCustomEntity | extend |