mirror of
https://github.com/zeek/zeek.git
synced 2025-10-07 17:18:20 +00:00

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
35 lines
1.5 KiB
Text
35 lines
1.5 KiB
Text
# These tests all check that ICMP6 events get raised with correct arguments.
|
|
|
|
# @TEST-EXEC: zeek -b -r $TRACES/icmp/icmp6-redirect-hdr-opt.pcap %INPUT >>output 2>&1
|
|
# @TEST-EXEC: zeek -b -r $TRACES/icmp/icmp6-nd-options.pcap %INPUT >>output 2>&1
|
|
|
|
# @TEST-EXEC: btest-diff output
|
|
|
|
event icmp_router_advertisement(c: connection, icmp: icmp_conn, cur_hop_limit: count, managed: bool, other: bool, home_agent: bool, pref: count, proxy: bool, rsv: count, router_lifetime: interval, reachable_time: interval, retrans_timer: interval, options: icmp6_nd_options)
|
|
{
|
|
print "icmp_router_advertisement options";
|
|
for ( o in options )
|
|
{
|
|
print fmt(" %s", options[o]);
|
|
if ( options[o]$otype == 1 && options[o]?$link_address )
|
|
print fmt(" MAC: %s",
|
|
string_to_ascii_hex(options[o]$link_address));
|
|
}
|
|
}
|
|
|
|
event icmp_neighbor_advertisement(c: connection, icmp: icmp_conn, router: bool, solicited: bool, override: bool, tgt: addr, options: icmp6_nd_options)
|
|
{
|
|
print "icmp_neighbor_advertisement options";
|
|
for ( o in options )
|
|
{
|
|
print fmt(" %s", options[o]);
|
|
if ( options[o]$otype == 2 && options[o]?$link_address ) print fmt(" MAC: %s", string_to_ascii_hex(options[o]$link_address));
|
|
}
|
|
}
|
|
|
|
event icmp_redirect(c: connection, icmp: icmp_conn, tgt: addr, dest: addr, options: icmp6_nd_options)
|
|
{
|
|
print "icmp_redirect options";
|
|
for ( o in options )
|
|
print fmt(" %s", options[o]);
|
|
}
|