Skip to content

Commit

Permalink
Check of correlation rules
Browse files Browse the repository at this point in the history
  • Loading branch information
thomaspatzke committed Feb 20, 2024
1 parent e42bec0 commit 5d5c010
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions sigma/cli/check.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,8 @@ def check(
f"Condition error in { str(condition.source) }:{ error }"
)
cond_errors.update((error,))
else:
check_rules.append(rule)

# TODO: From Python 3.10 the commented line below can be used.
rule_error_count = sum(rule_errors.values())
Expand Down
3 changes: 2 additions & 1 deletion tests/files/valid/sigma_correlation_rules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,10 @@ correlation:
condition:
gte: 10
---
title: Multiple occurrences of base event
title: Multiple occurrences of base event with different values
description: This is a correlation rule
id: 16a288b8-4ed2-440f-9984-7a128e86e006
date: 2023-12-09
status: test
level: medium
correlation:
Expand Down

0 comments on commit 5d5c010

Please sign in to comment.