Detection rules › Kusto

Cisco WSA - Unexpected file type

Status
available
Severity
medium
Time window
1h
Source
github.com/Azure/Azure-Sentinel

'Detects unexpected file type.'

MITRE ATT&CK coverage

TacticTechniques
Initial AccessT1189 Drive-by Compromise

Rule body kusto

id: 8e9d1f70-d529-4598-9d3e-5dd5164d1d02
name: Cisco WSA - Unexpected file type
description: |
  'Detects unexpected file type.'
severity: Medium
status: Available
requiredDataConnectors:
  - connectorId: SyslogAma
    datatypes:
      - Syslog
queryFrequency: 1h
queryPeriod: 1h
triggerOperator: gt
triggerThreshold: 0
tactics:
  - InitialAccess
relevantTechniques:
  - T1189
query: |
  CiscoWSAEvent
  | where isnotempty(AmpFileName)
  | where isempty(AmpThreatName)
  | where ResponseBodyMimeType =~ 'application/octet-stream'
  | where AmpFileName !endswith '.exe'
  | extend IPCustomEntity = SrcIpAddr, AccountCustomEntity = SrcUserName
entityMappings:
  - entityType: IP
    fieldMappings:
      - identifier: Address
        columnName: IPCustomEntity
  - entityType: Account
    fieldMappings:
      - identifier: Name
        columnName: AccountCustomEntity
version: 1.0.2
kind: Scheduled

Stages and Predicates

Stage 1: source

CiscoWSAEvent

Stage 2: where

| where isnotempty(AmpFileName)

Stage 3: where

| where isempty(AmpThreatName)

Stage 4: where

| where ResponseBodyMimeType =~ 'application/octet-stream'

Stage 5: where

| where AmpFileName !endswith '.exe'

Stage 6: extend

| extend IPCustomEntity = SrcIpAddr, AccountCustomEntity = SrcUserName

Exclusions

Top-level NOT(...) conjuncts: predicates this rule actively suppresses.

FieldKindExcluded values
AmpFileNameends_with.exe

Indicators

Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.

FieldKindValues
AmpFileNameis_not_null
  • (no value, null check)
AmpThreatNameis_null
  • (no value, null check)
ResponseBodyMimeTypeeq
  • application/octet-stream

Output fields

Fields the rule emits when it matches. Chronicle authors list these in the outcome block; they appear on the detection and $risk_score drives alerting. Sentinel / Defender XDR rules build them up through project / summarize / extend stages. Sentinel maps these into alert fields via entityMappings and customDetails; Defender XDR custom detections surface them as alert fields directly.

FieldSource
AccountCustomEntityextend
IPCustomEntityextend