Subject: Re: pfil and arp
To: Mike Pelley , NetBSD Tech-Net <tech-net@netbsd.org>
From: Ignatios Souvatzis <ignatios@cs.uni-bonn.de>
List: tech-net
Date: 06/03/1999 15:19:28
On Wed, Jun 02, 1999 at 03:21:04PM -0400, Mike Pelley wrote:
> There is a packet filter interface (pfil) in the kernel that allows a pseudo
> device to intercept ip packets with pfil_add_hook.  Does it make sense to
> extend this to capture ARP packets as well as IP packets?  pfil_add_hook
> could take a flag to specify which list of hooks you want to add yourself
> to - PFIL_IPIN, PFIL_IPOUT, PFIL_ARPIN, and PFIL_ARPOUT (just like the
> direction flag now).  I figured I could copy the for loop idea from
> ip_input/output to in_arpinput/output and add some arp stuff to the
> pfil.c/pfil.h.

If the PFIL architecture allows this, I whould suggest to use a seperate
"address familiy" or rather "protocol family" parameter, like PF_INET, PF_ARP,
PF_IPV6.

	-is