From owner-freebsd-current Fri Aug 23 10:29:49 1996 Return-Path: owner-current Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id KAA15526 for current-outgoing; Fri, 23 Aug 1996 10:29:49 -0700 (PDT) Received: from phaeton.artisoft.com (phaeton.Artisoft.COM [198.17.250.211]) by freefall.freebsd.org (8.7.5/8.7.3) with SMTP id KAA15272; Fri, 23 Aug 1996 10:27:29 -0700 (PDT) Received: (from terry@localhost) by phaeton.artisoft.com (8.6.11/8.6.9) id KAA16063; Fri, 23 Aug 1996 10:14:47 -0700 From: Terry Lambert Message-Id: <199608231714.KAA16063@phaeton.artisoft.com> Subject: Re: cvs commit: src/sys/netinet in.h ip_fw.h ip_input.c ip_output.c To: pst@jnx.com (Paul Traina) Date: Fri, 23 Aug 1996 10:14:46 -0700 (MST) Cc: sos@FreeBSD.org, rgrimes@GndRsh.aac.dev.com, archie@whistle.com, julian@whistle.com, current@FreeBSD.org In-Reply-To: <199608231648.JAA15997@base.jnx.com> from "Paul Traina" at Aug 23, 96 09:48:04 am X-Mailer: ELM [version 2.4 PL24] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-current@FreeBSD.org X-Loop: FreeBSD.org Precedence: bulk > By not agressive enough, I mean I think you have the right idea, but the > syntax > for the hook should be something like: > > for (hook = iphooks.ipinput.lh_first; hook; hook = hook->next) { > if (!(*hook)(IP_INPUT, &m, &ip)) > break; > } > > Basicly, we make a linked list of hooks and call them in order until one of > them swallows the packet or they're all complete. > > We do this for ip input processing, ip output processing, and perhaps as > suggested, in the IP raw input (packet received) processing section of the code. > > Then, if you want IP filtering, just add the hook to the generic "registry" Question: is there any particular reason this should be IP specific? Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.