Skip to content

Commit

Permalink
github-ci: check for duplicate SIDs in rules/
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonish authored and victorjulien committed Nov 24, 2020
1 parent 8bd6847 commit bb7f80e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,15 @@ jobs:

- uses: actions/checkout@v2

# Prebuild check for duplicat SIDs
- name: Check for duplicate SIDs
run: |
dups=$(sed -n 's/^alert.*sid:\([[:digit:]]*\);.*/\1/p' ./rules/*.rules|sort|uniq -d|tr '\n' ' ')
if [[ "${dups}" != "" ]]; then
echo "::error::Duplicate SIDs found:${dups}"
exit 1
fi
# Download and extract dependency archives created during prep
# job.
- uses: actions/download-artifact@v2
Expand Down

0 comments on commit bb7f80e

Please sign in to comment.