2. #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
5. 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
6. Uses of YARA?
• Triaging
• Memory Analysis
• Email Analysis
• Back Hunting
• Forward Hunting
9. 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
10. Writing YARA Rules
10
• Each rule consists:
• Set of strings
• Boolean expressions - Determine the
logic for detection
11. 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
12. Writing YARA
Rules
• condition:
• all of ($foo*)
• condition:
• $foo1 and $foo2 and $foo3 and
$foo4 and $foo5
• condition:
• $foo1 or $foo2
12
22. Problems
• Lots of data available online but in an
unstructured format
• Manual creation of queries due to different
formats in SIEM systems
• Mixed Environments
24. 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
25. 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