Detection & response

Sigma

A vendor-neutral YAML format for log-based detection rules that converts into SIEM query languages such as KQL, SPL and Elastic queries.

A Sigma rule declares a logsource (product, category, service), named detection selections using field modifiers (|contains, |endswith, |re), a condition combining them, plus metadata: ATT&CK tags, level, known false positives. pySigma backends and sigma-cli convert it into the target SIEM's language with field-mapping pipelines.

It does for log detections what YARA does for files: a shared language so the community can publish rules (the SigmaHQ repository) and so teams can migrate SIEMs without rewriting content. It fits naturally into detection as code: rules in git, tests in CI.

Pitfalls: conversion is only as good as the field mapping for your data, so validate converted queries against real logs; and complex correlation logic may need Sigma's correlation rules or native SIEM features.

Sigma ruleyaml
title: Certutil used to download a file
id: 9c0d1e6a-5b2f-4c7e-8a51-0d3f2b7e1c44
status: experimental
logsource:
  product: windows
  category: process_creation
detection:
  selection_img:
    Image|endswith: '\certutil.exe'
  selection_cli:
    CommandLine|contains|all:
      - 'urlcache'
      - 'http'
  condition: all of selection_*
falsepositives:
  - Rare administrative use
level: high
tags:
  - attack.command-and-control
  - attack.t1105

Learn it properly

Compared

Also used in

Related terms