zeek/testing
Christian Kreibich f97a33e14d Fix type clash fatal error with log filters that use $ext_func and $include/$exclude
The logging manager's Manager::TraverseRecord(), called when adding a
log filter to a stream, skipped any fields intoduced by a filter's
$ext_func when such fields weren't mentioned in a $include restriction
or mentioned in an $exclude restriction. This was inconsistent with
Manager::RecordToFilterVals, used when actually writing log entries,
which does include those values.

The result was that the record indices descent in Manager::RecordToFilterVals
expects to find only record values, when in fact only the record
provided by ext_func is present. This leads to type mismatches and
hard Zeek exits like this one:

1300475173.475401 fatal error in zeek/share/zeek//base/init-bare.zeek, line 4810: Val::CONVERTER (string/record) (zeek)

The fix makes ext_func's field additions decisive, meaning the
filter's include/exclude lists don't apply to it. If a user really
wants to override this, they can reset the filter's ext_func back to
our no-op default.

The included btest produces the above error when the fix is not present.
2020-11-10 18:13:16 -08:00
..
btest Fix type clash fatal error with log filters that use $ext_func and $include/$exclude 2020-11-10 18:13:16 -08:00
coverage Remove the entire auxil directory from the results 2020-10-23 19:44:51 +00:00
external Update external testing repo hashes for canonification updates 2020-11-10 09:02:30 -07:00
scripts GH-1149: Add GitHub Action to automate generation of zeek-docs 2020-09-01 17:52:00 -07:00
.gitignore
Makefile Added coverage to .PHONY in Makefile due to testing/coverage 2018-07-30 12:17:40 -07:00
README More bro-to-zeek renaming in the unit tests 2019-05-16 02:27:54 -05:00

This directory contains suites for testing for Zeek's correct
operation:

    btest/
        An ever-growing set of small unit tests testing Zeek's
        functionality.

    external/
        A framework for downloading additional test sets that run more
        complex Zeek configuration on larger traces files. Due to their
        size, these are not included directly. See the README for more
        information. 

    scripts/
        Helpers scripts used by some tests.