Skip to content

Commit

Permalink
Merge pull request #13049 from Security-Onion-Solutions/fix/detection…
Browse files Browse the repository at this point in the history
…s_alerts_component_template

Exclude detections from template name matching
  • Loading branch information
weslambert authored May 21, 2024
2 parents 3de6454 + deb140e commit 5aaf44e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ if [ ! -f $STATE_FILE_SUCCESS ]; then
for i in $pattern; do
TEMPLATE=${i::-14}
COMPONENT_PATTERN=${TEMPLATE:3}
MATCH=$(echo "$TEMPLATE" | grep -E "^so-logs-|^so-metrics" | grep -v osquery)
MATCH=$(echo "$TEMPLATE" | grep -E "^so-logs-|^so-metrics" | grep -vE "detections|osquery")
if [[ -n "$MATCH" && ! "$COMPONENT_LIST" =~ "$COMPONENT_PATTERN" ]]; then
load_failures=$((load_failures+1))
echo "Component template does not exist for $COMPONENT_PATTERN. The index template will not be loaded. Load failures: $load_failures"
Expand Down

0 comments on commit 5aaf44e

Please sign in to comment.