diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet/if_ether.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index 1bbe164..c123713 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -493,6 +493,12 @@ arpintr() * We no longer reply to requests for ETHERTYPE_TRAIL protocol either, * but formerly didn't normally send requests. */ +static int log_arp_wrong_iface = 1; + +SYSCTL_INT(_net_link_ether_inet, OID_AUTO, log_arp_wrong_iface, CTLFLAG_RW, + &log_arp_wrong_iface, 0, + "log arp packets arriving on the wrong interface"); + static void in_arpinput(m) struct mbuf *m; @@ -558,6 +564,7 @@ in_arpinput(m) if (la && (rt = la->la_rt) && (sdl = SDL(rt->rt_gateway))) { #ifndef BRIDGE /* the following is not an error when doing bridging */ if (rt->rt_ifp != &ac->ac_if) { + if (log_arp_wrong_iface) log(LOG_ERR, "arp: %s is on %s%d but got reply from %6D on %s%d\n", inet_ntoa(isaddr), rt->rt_ifp->if_name, rt->rt_ifp->if_unit, |