diff --git a/scapy/arch/bpf/pfroute.py b/scapy/arch/bpf/pfroute.py index 48ac739ff0c..6bbff0e7992 100644 --- a/scapy/arch/bpf/pfroute.py +++ b/scapy/arch/bpf/pfroute.py @@ -1042,6 +1042,8 @@ def read_routes(): if DARWIN and flags.RTF_WASCLONED and msg.rtm_parentflags.RTF_PRCLONING: # OSX needs filtering continue + if NETBSD and flags.RTF_LLDATA: + continue addrs = msg.rtm_addrs net = 0 mask = 0xFFFFFFFF @@ -1138,6 +1140,8 @@ def read_routes6(): if DARWIN and flags.RTF_WASCLONED and msg.rtm_parentflags.RTF_PRCLONING: # OSX needs filtering continue + if NETBSD and flags.RTF_LLDATA: + continue addrs = msg.rtm_addrs prefix = "::" plen = 128 diff --git a/test/regression.uts b/test/regression.uts index c1e673c4510..6cde4479336 100644 --- a/test/regression.uts +++ b/test/regression.uts @@ -3443,7 +3443,6 @@ assert routes == [ (2130706433, 4294967295, '0.0.0.0', 'lo0', '127.0.0.1', 1), (2887237632, 4294963200, '0.0.0.0', 'hvn0', '172.23.207.191', 1), (2887241663, 4294967295, '0.0.0.0', 'lo0', '172.23.207.191', 1), - (2887237633, 4294967295, '0.0.0.0', 'hvn0', '', 1), (3758096384, 4026531840, '0.0.0.0', 'hvn0', '172.23.207.191', 250), (3758096384, 4026531840, '0.0.0.0', 'lo0', '127.0.0.1', 250) ] @@ -3508,8 +3507,6 @@ assert routes == [ (167772687, 4294967295, '0.0.0.0', 'lo0', '10.0.2.15', 1), (2130706432, 4278190080, '127.0.0.1', 'lo0', '127.0.0.1', 1), (2130706433, 4294967295, '0.0.0.0', 'lo0', '127.0.0.1', 1), - (167772674, 4294967295, '0.0.0.0', 'wm0', '', 1), - (167772675, 4294967295, '0.0.0.0', 'wm0', '', 1), (3758096384, 4026531840, '0.0.0.0', 'wm0', '10.0.2.15', 250), (3758096384, 4026531840, '0.0.0.0', 'lo0', '127.0.0.1', 250) ] @@ -3563,8 +3560,6 @@ assert routes == [ ('ff01::', 32, '::1', 'lo0', ['::1'], 1), ('ff02::', 32, '::', 'wm0', ['fe80::a00:27ff:feed:60bb'], 1), ('ff02::', 32, '::1', 'lo0', ['::1'], 1), - ('fe80::2', 128, '::', 'wm0', [], 1), - ('fd17:625c:f037:2::3', 128, '::', 'wm0', [], 1), ('ff00::', 8, '::',