ci/live: test for sid 1 existence, not in last position

pull/14344/head
Philippe Antoine 1 year ago
parent 626027a456
commit bbebd02356

@ -70,7 +70,7 @@ if [ $STATSCHECK = false ]; then
echo "ERROR no packets captured"
RES=1
fi
SID1CHECK=$(jq -c 'select(.event_type == "alert")' ./eve.json | tail -n1 | jq '.alert.signature_id == 1')
SID1CHECK=$(jq -c 'select(.alert.signature_id == 1)' ./eve.json | wc -l)
if [ $SID1CHECK = false ]; then
echo "ERROR no alerts for sid 1"
RES=1

@ -61,7 +61,7 @@ if [ $STATSCHECK = false ]; then
echo "ERROR no packets captured"
RES=1
fi
SID1CHECK=$(jq -c 'select(.event_type == "alert")' ./eve.json | tail -n1 | jq '.alert.signature_id == 1')
SID1CHECK=$(jq -c 'select(.alert.signature_id == 1)' ./eve.json | wc -l)
if [ $SID1CHECK = false ]; then
echo "ERROR no alerts for sid 1"
RES=1

Loading…
Cancel
Save