mirror of
https://github.com/ghndrx/prowler.git
synced 2026-02-10 14:55:00 +00:00
Return default behaviour to previous, remove distinction between strict & non-strict matching
This commit is contained in:
@@ -114,13 +114,8 @@ textFail(){
|
||||
while read -r i; do
|
||||
ignore_check_name="${i%%:*}" # Check name is everything up to the first :
|
||||
ignore_value="${i#*${CHECK_NAME}:}" # Ignore value is everything after the first :
|
||||
if [[ ${ignore_value} =~ .*:f ]]; then
|
||||
# Fuzzy search - if this pattern appears anywhere in the line, it matches.
|
||||
resource_value=".*${ignore_value%:*}.*"
|
||||
else
|
||||
# Strict search - pattern has to be its own word.
|
||||
resource_value="[[:space:]^]${ignore_value}[[:space:]$]"
|
||||
fi
|
||||
# Check to see if ignore value appears anywhere within log message.
|
||||
resource_value=".*${ignore_value}.*"
|
||||
if [[ ${ignore_check_name} != "${CHECK_NAME}" ]]; then
|
||||
# not for this check
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user