Skip to content

Commit

Permalink
Merge pull request #11180 from dodys/nftables
Browse files Browse the repository at this point in the history
Ubuntu: nftables: Improve SCE
  • Loading branch information
Mab879 authored Oct 9, 2023
2 parents d5a041f + f8e656d commit a9a56a7
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
# Check if default policy is drop
output=$(nft list ruleset)

if ! (grep 'hook input' "$output" |& grep -w 'policy drop' &>/dev/null &&\
grep 'hook forward' "$output" |& grep -w 'policy drop' &>/dev/null &&\
grep 'hook output' "$output" |& grep -w 'policy drop' &>/dev/null); then
if ! (echo "$output" | grep 'hook input' |& grep -wq 'policy drop' &&\
echo "$output" | grep 'hook forward' |& grep -wq 'policy drop' &&\
echo "$output" | grep 'hook output' |& grep -wq 'policy drop'); then
exit "${XCCDF_RESULT_FAIL}"
fi

Expand Down

0 comments on commit a9a56a7

Please sign in to comment.