fix
This commit is contained in:
parent
503c40cad3
commit
037bc45467
|
@ -416,11 +416,11 @@ fi
|
|||
BODY_CONTAINS=" "
|
||||
if [ -n "$CRIT_STRING" ]; then
|
||||
BODY=$(curl -s $FOLLOW_REDIRECTS $INSECURE $HEADERS $RESOLVE $TIMEOUT $URL)
|
||||
if $SANITIZE_HTML; then
|
||||
BODY=$(echo "$BODY" | sed 's/</\</g' | sed 's/>/\>/g')
|
||||
fi
|
||||
# shellcheck disable=SC2076
|
||||
if ! [[ $BODY =~ "$CRIT_STRING" ]]; then
|
||||
if $SANITIZE_HTML; then
|
||||
BODY=$(echo "$BODY" | sed 's/</\</g' | sed 's/>/\>/g')
|
||||
fi
|
||||
echo "CRITICAL - response body does not contain the required string: $BODY"
|
||||
exit 2
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue