zeek/testing/btest/signatures/bad-eval-condition.zeek
Jon Siwek 7967a5b0aa General btest cleanup
- Use `-b` most everywhere, it will save time.

- Start some intel tests upon the input file being fully read instead of
  at an arbitrary time.

- Improve termination condition for some sumstats/cluster tests.

- Filter uninteresting output from some supervisor tests.

- Test for `notice_policy.log` is no longer needed.
2020-08-11 11:26:22 -07:00

22 lines
482 B
Text

# @TEST-EXEC-FAIL: zeek -b -r $TRACES/ftp/ipv4.trace %INPUT
# @TEST-EXEC: TEST_DIFF_CANONIFIER=$SCRIPTS/diff-remove-abspath btest-diff .stderr
@load-sigs blah.sig
@TEST-START-FILE blah.sig
signature blah
{
ip-proto == tcp
src-port == 21
payload /.*/
eval mark_conn
}
@TEST-END-FILE
# wrong function signature for use with signature 'eval' conditions
# needs to be reported
function mark_conn(state: signature_state): bool
{
add state$conn$service["blah"];
return T;
}