GH-239: Rename bro to zeek, bro-config to zeek-config, and bro-path-dev to zeek-path-dev.

This also installs symlinks from "zeek" and "bro-config" to a wrapper
script that prints a deprecation warning.

The btests pass, but this is still WIP. broctl renaming is still
missing.

#239
This commit is contained in:
Robin Sommer 2019-04-23 14:25:56 +02:00
parent 375b151a4b
commit 789cb376fd
1119 changed files with 1686 additions and 1647 deletions

View file

@ -1,5 +1,5 @@
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh-new-default.log
# @TEST-EXEC: test '!' -e ssh.log

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,8 +1,8 @@
# @TEST-DOC: Test that the ASCII writer logs values of type "double" correctly.
#
# @TEST-EXEC: bro -b %INPUT test-json.zeek
# @TEST-EXEC: zeek -b %INPUT test-json.zeek
# @TEST-EXEC: mv test.log json.log
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.log
# @TEST-EXEC: btest-diff json.log
#

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: cat ssh.log | grep -v PREFIX.*20..- >ssh-filtered.log
# @TEST-EXEC: btest-diff ssh-filtered.log

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b %INPUT >output
# @TEST-EXEC: zeek -b %INPUT >output
# @TEST-EXEC: btest-diff test.log
# @TEST-EXEC: btest-diff output

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.log
redef LogAscii::empty_field = "EMPTY";

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.log
module Test;

View file

@ -1,4 +1,4 @@
#
# @TEST-EXEC: bro -C -r $TRACES/www-odd-url.trace
# @TEST-EXEC: zeek -C -r $TRACES/www-odd-url.trace
# @TEST-EXEC: btest-diff http.log

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.log
module Test;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: cat ssh.log | egrep -v '#open|#close' >ssh.log.tmp && mv ssh.log.tmp ssh.log
# @TEST-EXEC: btest-diff ssh.log

View file

@ -1,6 +1,6 @@
# Test that log rotation works with compressed logs.
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: gunzip test.*.log.gz
#

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: gunzip ssh.log.gz
# @TEST-EXEC: btest-diff ssh.log
# @TEST-EXEC: btest-diff ssh-uncompressed.log

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
#
# Testing all possible types.

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff testing.log
@load tuning/json-logs

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
#
# Testing all possible types.

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.log
module Test;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
redef LogAscii::output_to_stdout = F;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.log
module Test;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: cat ssh.log | grep -v PREFIX.*20..- >ssh-filtered.log
# @TEST-EXEC: btest-diff ssh-filtered.log

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: test '!' -e ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,2 +1,2 @@
# @TEST-EXEC: BRO_LOG_SUFFIX=txt bro -r $TRACES/wikipedia.trace
# @TEST-EXEC: BRO_LOG_SUFFIX=txt zeek -r $TRACES/wikipedia.trace
# @TEST-EXEC: test -f conn.txt

View file

@ -1,5 +1,5 @@
# @TEST-EXEC: bro -b %INPUT >output
# @TEST-EXEC: zeek -b %INPUT >output
# @TEST-EXEC: btest-diff output
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,8 +1,8 @@
# @TEST-PORT: BROKER_PORT1
# @TEST-PORT: BROKER_PORT2
#
# @TEST-EXEC: btest-bg-run manager-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=manager-1 bro %INPUT"
# @TEST-EXEC: btest-bg-run worker-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=worker-1 bro --pseudo-realtime -C -r $TRACES/wikipedia.trace %INPUT"
# @TEST-EXEC: btest-bg-run manager-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=manager-1 zeek %INPUT"
# @TEST-EXEC: btest-bg-run worker-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=worker-1 zeek --pseudo-realtime -C -r $TRACES/wikipedia.trace %INPUT"
# @TEST-EXEC: btest-bg-wait 20
# @TEST-EXEC: grep qux manager-1/reporter.log | sed 's#line ..#line XX#g' > manager-reporter.log
# @TEST-EXEC: grep qux manager-1/reporter-2.log | sed 's#line ..*#line XX#g' >> manager-reporter.log

View file

@ -1,8 +1,8 @@
# @TEST-PORT: BROKER_PORT1
# @TEST-PORT: BROKER_PORT2
#
# @TEST-EXEC: btest-bg-run manager-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=manager-1 bro %INPUT"
# @TEST-EXEC: btest-bg-run worker-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=worker-1 bro --pseudo-realtime -C -r $TRACES/wikipedia.trace %INPUT"
# @TEST-EXEC: btest-bg-run manager-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=manager-1 zeek %INPUT"
# @TEST-EXEC: btest-bg-run worker-1 "cp ../cluster-layout.zeek . && CLUSTER_NODE=worker-1 zeek --pseudo-realtime -C -r $TRACES/wikipedia.trace %INPUT"
# @TEST-EXEC: btest-bg-wait 20
# @TEST-EXEC: btest-diff manager-1/http.log

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
@load base/protocols/conn

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/http/get.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/http/get.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
# @TEST-EXEC: btest-diff .stderr

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
@load base/protocols/conn

View file

@ -1,4 +1,4 @@
# @TEST-EXEC-FAIL: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC-FAIL: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: TEST_DIFF_CANONIFIER=$SCRIPTS/diff-remove-abspath btest-diff .stderr
@load base/protocols/conn

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
@load base/protocols/conn

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
@load base/protocols/conn

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/auth_change_session_keys.pcap %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/auth_change_session_keys.pcap %INPUT
# @TEST-EXEC: btest-diff conn.log
# The other tests of Log::default_field_name_map used to not catch an invalid

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: test '!' -e ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT >output
# @TEST-EXEC: zeek -b %INPUT >output
# @TEST-EXEC: btest-diff output
redef Log::default_writer = Log::WRITER_NONE;

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff local.log
# @TEST-EXEC: btest-diff remote.log
#

View file

@ -1,5 +1,5 @@
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: ( ls static-*; cat static-* ) >output
# @TEST-EXEC: btest-diff output

View file

@ -1,5 +1,5 @@
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff test.success.log
# @TEST-EXEC: btest-diff test.failure.log

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b -B logging %INPUT
# @TEST-EXEC: zeek -b -B logging %INPUT
# @TEST-EXEC: btest-diff ssh.log
# @TEST-EXEC: btest-diff ssh.failure.log
# @TEST-EXEC: btest-diff .stdout

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b -r ${TRACES}/rotation.trace %INPUT | egrep "test|test2" | sort >out.tmp
# @TEST-EXEC: zeek -b -r ${TRACES}/rotation.trace %INPUT | egrep "test|test2" | sort >out.tmp
# @TEST-EXEC: cat out.tmp pp.log | sort >out
# @TEST-EXEC: for i in `ls test*.log | sort`; do printf '> %s\n' $i; cat $i; done | sort | $SCRIPTS/diff-remove-timestamps | uniq >>out
# @TEST-EXEC: btest-diff out

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b -r ${TRACES}/rotation.trace %INPUT >bro.out 2>&1
# @TEST-EXEC: zeek -b -r ${TRACES}/rotation.trace %INPUT >bro.out 2>&1
# @TEST-EXEC: grep "test" bro.out | sort >out
# @TEST-EXEC: for i in `ls test.*.log | sort`; do printf '> %s\n' $i; cat $i; done >>out
# @TEST-EXEC: btest-diff out

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
@load base/protocols/conn

View file

@ -1,7 +1,7 @@
# This tests the order in which the unrolling and field name
# renaming occurs.
# @TEST-EXEC: bro -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -b -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff conn.log
@load base/protocols/conn

View file

@ -4,7 +4,7 @@
# @TEST-GROUP: sqlite
#
# @TEST-EXEC: cat ssh.sql | sqlite3 ssh.sqlite
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff .stderr
#
# Testing all possible types.

View file

@ -6,7 +6,7 @@
# @TEST-REQUIRES: has-writer Bro::SQLiteWriter
# @TEST-GROUP: sqlite
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: sqlite3 ssh.sqlite 'select * from ssh' > ssh.select
# @TEST-EXEC: btest-diff ssh.select
#

View file

@ -4,7 +4,7 @@
# @TEST-REQUIRES: has-writer Bro::SQLiteWriter
# @TEST-GROUP: sqlite
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: sqlite3 ssh.sqlite 'select * from ssh' > ssh.select
# @TEST-EXEC: sqlite3 ssh.sqlite 'select * from sshtwo' >> ssh.select
# @TEST-EXEC: btest-diff ssh.select

View file

@ -3,7 +3,7 @@
# @TEST-REQUIRES: has-writer Bro::SQLiteWriter
# @TEST-GROUP: sqlite
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: sqlite3 ssh.sqlite 'select * from ssh' > ssh.select
# @TEST-EXEC: btest-diff ssh.select
#

View file

@ -3,7 +3,7 @@
# @TEST-REQUIRES: has-writer Bro::SQLiteWriter
# @TEST-GROUP: sqlite
#
# @TEST-EXEC: bro -r $TRACES/wikipedia.trace Log::default_writer=Log::WRITER_SQLITE
# @TEST-EXEC: zeek -r $TRACES/wikipedia.trace Log::default_writer=Log::WRITER_SQLITE
# @TEST-EXEC: sqlite3 conn.sqlite 'select * from conn order by ts' | sort -n > conn.select
# @TEST-EXEC: sqlite3 http.sqlite 'select * from http order by ts' | sort -n > http.select
# @TEST-EXEC: btest-diff conn.select

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT >output
# @TEST-EXEC: zeek -b %INPUT >output
# @TEST-EXEC: btest-diff output
# @TEST-EXEC: test '!' -e ssh.log

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
#
# Testing all possible types.

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff testing.log
redef enum Log::ID += { TESTING };

View file

@ -1,5 +1,5 @@
#
# @TEST-EXEC: bro -b %INPUT
# @TEST-EXEC: zeek -b %INPUT
# @TEST-EXEC: btest-diff ssh.log
module SSH;

View file

@ -1,4 +1,4 @@
# @TEST-EXEC: bro -C -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: zeek -C -r $TRACES/wikipedia.trace %INPUT
# @TEST-EXEC: btest-diff reporter.log
# @TEST-EXEC: btest-diff http.log
# @TEST-EXEC: btest-diff http-2.log