mirror of
https://github.com/zeek/zeek.git
synced 2025-10-06 00:28:21 +00:00

Instead of loading listen.bro to block until files are read, just read a pcap file in pseudo-realtime. Seems to work well.
25 lines
534 B
Text
25 lines
534 B
Text
# @TEST-EXEC: btest-bg-run bro bro -b --pseudo-realtime -r $TRACES/socks.trace %INPUT
|
|
# @TEST-EXEC: btest-bg-wait -k 5
|
|
# @TEST-EXEC: btest-diff bro/.stderr
|
|
|
|
global outfile: file;
|
|
global try: count;
|
|
|
|
module A;
|
|
|
|
type Val: record {
|
|
i: int;
|
|
b: bool;
|
|
};
|
|
|
|
event line(description: Input::EventDescription, tpe: Input::Event, i: int, b: bool)
|
|
{
|
|
}
|
|
|
|
event bro_init()
|
|
{
|
|
try = 0;
|
|
outfile = open("../out");
|
|
Input::add_event([$source="does-not-exist.dat", $name="input", $fields=Val, $ev=line, $want_record=F]);
|
|
Input::remove("input");
|
|
}
|