67 строки
2.4 KiB
YAML
67 строки
2.4 KiB
YAML
id: 85aca4d1-5d15-4001-abd9-acb86ca1786a
|
|
name: (Preview) TI map Domain entity to DnsEvent
|
|
description: |
|
|
'Identifies a match in DnsEvent table from any Domain IOC from TI'
|
|
severity: Medium
|
|
requiredDataConnectors:
|
|
- connectorId: DNS
|
|
dataTypes:
|
|
- DnsEvents
|
|
- connectorId: ThreatIntelligence
|
|
dataTypes:
|
|
- ThreatIntelligenceIndicator
|
|
- connectorId: ThreatIntelligenceTaxii
|
|
dataTypes:
|
|
- ThreatIntelligenceIndicator
|
|
queryFrequency: 1h
|
|
queryPeriod: 14d
|
|
triggerOperator: gt
|
|
triggerThreshold: 0
|
|
tactics:
|
|
- Impact
|
|
query: |
|
|
|
|
let dt_lookBack = 1h;
|
|
let ioc_lookBack = 14d;
|
|
//Create a list of TLDs in our threat feed for later validation
|
|
let list_tlds = ThreatIntelligenceIndicator
|
|
| where TimeGenerated > ago(ioc_lookBack)
|
|
| where isnotempty(DomainName)
|
|
| extend parts = split(DomainName, '.')
|
|
| extend tld = parts[(array_length(parts)-1)]
|
|
| summarize count() by tostring(tld)
|
|
| summarize make_list(tld);
|
|
ThreatIntelligenceIndicator
|
|
| where TimeGenerated >= ago(ioc_lookBack) and ExpirationDateTime > now()
|
|
| where Active == true
|
|
// Picking up only IOC's that contain the entities we want
|
|
| where isnotempty(DomainName)
|
|
| join (
|
|
DnsEvents
|
|
| where TimeGenerated > ago(dt_lookBack)
|
|
//Extract domain patterns from syslog message
|
|
| where isnotempty(Name)
|
|
| extend parts = split(Name, '.')
|
|
//Split out the TLD
|
|
| extend tld = parts[(array_length(parts)-1)]
|
|
//Validate parsed domain by checking if the TLD is in the list of TLDs in our threat feed
|
|
| where tld in~ (list_tlds)
|
|
| extend DNS_TimeGenerated = TimeGenerated
|
|
) on $left.DomainName==$right.Name
|
|
| summarize LatestIndicatorTime = arg_max(TimeGenerated, *) by IndicatorId
|
|
| project LatestIndicatorTime, Description, ActivityGroupNames, IndicatorId, ThreatType, ExpirationDateTime, ConfidenceScore, Url, DNS_TimeGenerated, Computer, ClientIP, Name, QueryType
|
|
| extend timestamp = DNS_TimeGenerated, HostCustomEntity = Computer, IPCustomEntity = ClientIP, URLCustomEntity = Url
|
|
entityMappings:
|
|
- entityType: Host
|
|
fieldMappings:
|
|
- identifier: FullName
|
|
columnName: HostCustomEntity
|
|
- entityType: IP
|
|
fieldMappings:
|
|
- identifier: Address
|
|
columnName: IPCustomEntity
|
|
- entityType: URL
|
|
fieldMappings:
|
|
- identifier: Url
|
|
columnName: URLCustomEntity
|