mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00

- Added a test for binpac exception handling -- the generated code should use "binpac::Exception" and not "Exception" for exception handling logic to avoid accidental overshadowing by the analyzer-specific type "binpac::ModbusTCP::Exception", which could lead to interesting asserts being triggered in binpac. - Update baseline for the event coverage test -- seems that more events get generated with working exception handling in the generated binpac parser code. - Coverage baseline was giving wrong number of events covered.
10 lines
557 B
Text
10 lines
557 B
Text
# @TEST-EXEC: bro -r $TRACES/modbus/fuzz-72.trace
|
|
# @TEST-EXEC: btest-diff modbus.log
|
|
# @TEST-EXEC: btest-diff weird.log
|
|
|
|
# The pcap has a flow with some fuzzed modbus traffic in it that should cause
|
|
# the binpac-generated analyzer code to throw a binpac::ExceptionOutOfBound.
|
|
# This should be correctly caught as a type of binpac::Exception and the
|
|
# binpac::ModbusTCP::Exception type that's defined as part of the analyzer
|
|
# shouldn't interfere with that handling and definitely shouldn't crash bro.
|
|
# A weird is currently emitted for parsing exceptions.
|