mirror of
https://github.com/zeek/zeek.git
synced 2025-10-04 23:58:20 +00:00

Netcontrol log now includes more information; before that, it had not quite caught up to the new capabilities (like flow modifying and redirection, as well as mac addresses). Furthermore, this fixes a number of bugs with cluster mode (like duplicate events), test failures due to updates in Bro, etc.
19 lines
504 B
Text
19 lines
504 B
Text
# @TEST-EXEC: bro -r $TRACES/tls/ecdhe.pcap %INPUT
|
|
# @TEST-EXEC: btest-diff netcontrol.log
|
|
# @TEST-EXEC: btest-diff openflow.log
|
|
|
|
@load base/frameworks/netcontrol
|
|
|
|
global of_controller: OpenFlow::Controller;
|
|
|
|
event bro_init()
|
|
{
|
|
of_controller = OpenFlow::log_new(42);
|
|
local netcontrol_of = NetControl::create_openflow(of_controller);
|
|
NetControl::activate(netcontrol_of, 0);
|
|
}
|
|
|
|
event connection_established(c: connection)
|
|
{
|
|
NetControl::quarantine_host(c$id$orig_h, 8.8.8.8, 192.169.18.1, 10hrs);
|
|
}
|