U

Ultimate Threat Hunting Sigma Toolkit

A comprehensive skill that enables use detection rules to hunt threats and analyze events. Built for Claude Code with best practices and real-world patterns.

SkillCommunitysecurityv1.0.0MIT
0 views0 copies

Threat Hunting with Sigma Toolkit

Advanced threat hunting framework using Sigma detection rules to identify suspicious activities across log sources, build detection logic, and automate security monitoring workflows.

When to Use This Skill

Choose Threat Hunting with Sigma when:

  • Building detection rules for security monitoring
  • Hunting for indicators of compromise across log sources
  • Translating threat intelligence into actionable detections
  • Standardizing detection logic across multiple SIEM platforms
  • Validating that security controls detect known attack techniques

Consider alternatives when:

  • Need real-time response automation — use SOAR platforms
  • Performing vulnerability scanning — use dedicated scanners
  • Need endpoint detection — use EDR agent rules

Quick Start

# Activate Sigma toolkit claude skill activate ultimate-threat-hunting-sigma-toolkit # Create a detection rule claude "Write a Sigma rule to detect PowerShell encoded command execution" # Convert for your SIEM claude "Convert this Sigma rule to Splunk SPL and Elastic query"

Example Sigma Rule

title: Suspicious PowerShell Encoded Command id: f3a1b2c3-d4e5-6789-abcd-ef0123456789 status: production description: Detects PowerShell execution with Base64 encoded commands references: - https://attack.mitre.org/techniques/T1059/001/ author: Security Team date: 2024/03/15 tags: - attack.execution - attack.t1059.001 logsource: category: process_creation product: windows detection: selection_cmd: CommandLine|contains: - '-enc ' - '-EncodedCommand ' - '-encodedcommand ' Image|endswith: '\powershell.exe' filter_legitimate: ParentImage|endswith: - '\sccm\\' - '\ccmexec.exe' condition: selection_cmd and not filter_legitimate falsepositives: - SCCM client operations - Legitimate admin automation scripts level: high

Core Concepts

Sigma Rule Structure

ComponentDescriptionRequired
titleDescriptive name for the detectionYes
idUUID for rule identificationYes
statustest, experimental, production, deprecatedYes
logsourceLog source specification (category, product, service)Yes
detectionDetection logic with selections and conditionsYes
levelSeverity: informational, low, medium, high, criticalYes
tagsMITRE ATT&CK technique referencesRecommended
falsepositivesKnown false positive scenariosRecommended

MITRE ATT&CK Mapping

TacticCommon TechniquesSigma Log Source
Initial AccessPhishing (T1566), Exploit Public App (T1190)proxy, email
ExecutionPowerShell (T1059.001), Command Line (T1059.003)process_creation
PersistenceRegistry Run Keys (T1547.001), Scheduled Tasks (T1053.005)registry, sysmon
Defense EvasionObfuscation (T1027), Disable Security (T1562)process_creation, security
Credential AccessBrute Force (T1110), Kerberoasting (T1558.003)authentication, security
Lateral MovementRDP (T1021.001), SMB (T1021.002)network, authentication
ExfiltrationDNS Tunneling (T1048.003), Cloud Storage (T1567.002)dns, proxy
# Sigma CLI operations # Convert rule to Splunk SPL sigma convert -t splunk -p sysmon rule.yml # Convert to Elastic Query sigma convert -t elasticsearch rule.yml # Validate rule syntax sigma check rule.yml # Convert entire rule directory sigma convert -t splunk -p sysmon -r rules/ -o splunk_queries/ # Test rule against sample log sigma convert -t sqlite rule.yml | sqlite3 logs.db

Configuration

ParameterDescriptionDefault
target_siemTarget SIEM for rule conversionsplunk
pipelineProcessing pipeline (sysmon, windows, linux)sysmon
rule_formatOutput: sigma, splunk, elastic, qradar, sentinelsigma
attack_versionMITRE ATT&CK version for tagging14.0
validate_on_saveValidate rule syntax before savingtrue
include_test_dataGenerate test log samples for rulesfalse

Best Practices

  1. Start with high-confidence, low-noise detections — Begin with rules that have few false positives and clear attack indicators. PowerShell encoded commands, LSASS memory access, and scheduled task creation from unusual paths are reliable starting points with well-understood behavior.

  2. Map every rule to MITRE ATT&CK techniques — Tagging rules with ATT&CK technique IDs enables coverage analysis. You can quickly identify which tactics and techniques have detection coverage and where blind spots exist in your monitoring.

  3. Include false positive documentation in every rule — Document known legitimate behaviors that trigger the rule. This saves analysts investigation time and provides context for tuning. Rules without false positive documentation generate alert fatigue and lose analyst trust.

  4. Test rules against both attack samples and baseline traffic — Validate that rules detect known attack patterns using tools like Atomic Red Team. Equally important, run rules against baseline logs to measure false positive rates before deploying to production.

  5. Version control your detection rules — Store Sigma rules in git with meaningful commit messages linking to threat intelligence or incident reports that motivated the rule. This provides an audit trail of your detection capability evolution.

Common Issues

Rules generate excessive false positives after deployment to production. Tune detection conditions by adding filter exclusions for known-good processes, paths, and users specific to your environment. Use the falsepositives field to document exclusions and review them quarterly — excluded items can become attack vectors if attackers learn your filter patterns.

Sigma rule conversion produces syntax errors in the target SIEM. Different SIEM platforms have varying query capabilities. Some Sigma features (regex, near operators, aggregation) don't translate cleanly to all targets. Test converted queries manually before automation and maintain target-specific overrides for rules that require platform-specific syntax.

Threat hunting produces overwhelming volumes of data without actionable findings. Narrow your hypothesis before querying. Start with specific indicators from threat intelligence, then broaden if initial results are empty. Use time-bounded searches with focused field selections rather than open-ended full-text searches across all logs.

Community

Reviews

Write a review

No reviews yet. Be the first to review this template!

Similar Templates