SlideShare a Scribd company logo
YARA & SIGMA
Rules
Lionel Faleiro
1
#WHOAMI
• Lionel Faleiro
• Practice Lead – Forensics
• 10 years experience in IT and Cybersecurity
• Key Domains – Malware Analysis, Log
Analysis, IR and Security Analytics, Training
• Gamer, Photographer
• @sandmaxprime
3
Yara
4
What is YARA?
• A detection rule system for files
• Based upon defined patterns or
characteristics
• Developed by Victor Alvarez of
Virustotal
• Open-Source System which is
primarily used for Malware
Hunting
• Has extension of .YAR
• Filtration
• Hunting
Uses of YARA?
• Triaging
• Memory Analysis
• Email Analysis
• Back Hunting
• Forward Hunting
Who Uses YARA?
• Cuckoo Sandbox
• ESET
• FireEye
• Joe Security
Who Uses YARA?
• Kaspersky Lab
• PhishMe
• Tenable
• LOKI
8
Writing YARA Rules
• Pros:
• Easy to Understand
• Easily sharable
• Cons:
• Runs slowly on large number of
files
• Issues running against files that
are packed or having obfuscation
• Need to be written manually
Writing YARA Rules
10
• Each rule consists:
• Set of strings
• Boolean expressions - Determine the
logic for detection
Writing YARA
Rules
• Text strings
• Hex strings are placed inside parenthesis
• Regular expressions are enclosed in backslashes
• Yara keywords:
• all, and, any, ascii, at, condition, contains,
entrypoint, false, filesize, fullword, for,
global, in, import, include, int8, int16, int32,
matches, meta. nocase, not, or, of, private,
rule, strings, them, true, uint8, uint16,
uint32, wide.
11
Writing YARA
Rules
• condition:
• all of ($foo*)
• condition:
• $foo1 and $foo2 and $foo3 and
$foo4 and $foo5
• condition:
• $foo1 or $foo2
12
Writing YARA
Rules
13
Hafnium
Privileged & Confidential | ©2021, Network Intelligence. All Rights Reserved. 14
Hafnium
Detection
15
Hafnium
Detection
16
Hafnium Detection
Other Tools
SIGMA Rules
19
Log File To Detection
Log Files SIEM
Search
Correlation
Manual
Analysis
Sample Events
Account Process Windows Application
Problems
• Lots of data available online but in an
unstructured format
• Manual creation of queries due to different
formats in SIEM systems
• Mixed Environments
Unleash SIGMA
What is SIGMA?
• Open-source rule system to be
used by SIEM’s
• Rule format is a very structured
format
• Mapped to Log Events
• Rules are written in YAML
• Open repository present for ules
24
Use Cases of
SIGMA?
• Describe the detection methods
and make it available.
• Invest in generating rules for Sigma
and use on many different (e.g.
SIEM) systems.
• Use Sigma to share the signature
with other threat intel
communities.
25
Supported
Vendors
26
Privileged
&
Confidential
|
©2021,
Network
Intelligence.
All
Rights
Reserved.
27
SIGMA Rule
Structure
• Metadata (id, tags, author, title,
references, level)
• Scope - Log source
• Search Parameters – values, ID
• Condition
28
Sigma and YARA Rules
SIGMAUI
SIGMAUI
Hafnium
SIGMA
32
Hafnium SIGMA
33
Hafnium SIGMA
34
References
• SIGMA Rule Wiki -
https://github.com/SigmaHQ/sigma/wiki/Sp
ecification
• SIGMA Repo -
https://github.com/SigmaHQ/sigma
• Yara Rules Repo - https://github.com/Yara-
Rules/rules
• YarGen -
https://github.com/Neo23x0/yarGen
• Yara Wiki -
https://yara.readthedocs.io/en/v3.4.0/writin
grules.html
Sigma and YARA Rules

More Related Content

PDF
Upping the APT hunting game: learn the best YARA practices from Kaspersky
PDF
Threat Hunting, Detection, and Incident Response in the Cloud
PDF
Introduction to YARA rules
PPTX
Advanced Persistent Threats (APTs) - Information Security Management
PPTX
Hunting for APT in network logs workshop presentation
PDF
Stopping zero day threats
PPTX
SIEM - Your Complete IT Security Arsenal
PDF
No Easy Breach DerbyCon 2016
Upping the APT hunting game: learn the best YARA practices from Kaspersky
Threat Hunting, Detection, and Incident Response in the Cloud
Introduction to YARA rules
Advanced Persistent Threats (APTs) - Information Security Management
Hunting for APT in network logs workshop presentation
Stopping zero day threats
SIEM - Your Complete IT Security Arsenal
No Easy Breach DerbyCon 2016

What's hot (20)

PDF
50 Shades of Sigma
PDF
Sigma Hall of Fame - EU ATT&CK User Workshop, October 2021
PDF
SIEM Architecture
PPTX
Cyber Threat Hunting Workshop
PPTX
Security Information and Event Management (SIEM)
PPTX
Security Information and Event Management (SIEM)
PPTX
SIEM : Security Information and Event Management
PPTX
SIEM Primer:
PPTX
OWASP Top 10 2021 What's New
PDF
Secure by Design - Security Design Principles for the Rest of Us
PPTX
OWASP Top 10 2021 Presentation (Jul 2022)
PPTX
Threat hunting for Beginners
PDF
Upgrade Your SOC with Cortex XSOAR & Elastic SIEM
PPTX
Cyber kill chain
PDF
Threat hunting 101 by Sandeep Singh
PPTX
Bsides 2019 - Intelligent Threat Hunting
PDF
IBM Qradar
PPTX
IBM Security QRadar
PDF
Introduction to MITRE ATT&CK
PPTX
MITRE ATT&CK framework
50 Shades of Sigma
Sigma Hall of Fame - EU ATT&CK User Workshop, October 2021
SIEM Architecture
Cyber Threat Hunting Workshop
Security Information and Event Management (SIEM)
Security Information and Event Management (SIEM)
SIEM : Security Information and Event Management
SIEM Primer:
OWASP Top 10 2021 What's New
Secure by Design - Security Design Principles for the Rest of Us
OWASP Top 10 2021 Presentation (Jul 2022)
Threat hunting for Beginners
Upgrade Your SOC with Cortex XSOAR & Elastic SIEM
Cyber kill chain
Threat hunting 101 by Sandeep Singh
Bsides 2019 - Intelligent Threat Hunting
IBM Qradar
IBM Security QRadar
Introduction to MITRE ATT&CK
MITRE ATT&CK framework
Ad

Recently uploaded (20)

PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
Cloud computing and distributed systems.
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Approach and Philosophy of On baking technology
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PDF
Electronic commerce courselecture one. Pdf
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Spectral efficient network and resource selection model in 5G networks
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
CIFDAQ's Market Insight: SEC Turns Pro Crypto
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
Machine learning based COVID-19 study performance prediction
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPT
Teaching material agriculture food technology
PDF
Modernizing your data center with Dell and AMD
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Cloud computing and distributed systems.
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Approach and Philosophy of On baking technology
Unlocking AI with Model Context Protocol (MCP)
Diabetes mellitus diagnosis method based random forest with bat algorithm
Electronic commerce courselecture one. Pdf
Understanding_Digital_Forensics_Presentation.pptx
Spectral efficient network and resource selection model in 5G networks
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Encapsulation_ Review paper, used for researhc scholars
Reach Out and Touch Someone: Haptics and Empathic Computing
CIFDAQ's Market Insight: SEC Turns Pro Crypto
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
Machine learning based COVID-19 study performance prediction
“AI and Expert System Decision Support & Business Intelligence Systems”
Teaching material agriculture food technology
Modernizing your data center with Dell and AMD
Ad

Sigma and YARA Rules