Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Jun 1999 11:05:16 +0200 (MET DST)
From:      Luigi Rizzo <luigi@labinfo.iet.unipi.it>
To:        stan@osgroup.com
Cc:        hackers@FreeBSD.ORG
Subject:   Re: ipfilter (was: RE: Introduction)
Message-ID:  <199906210905.LAA21570@labinfo.iet.unipi.it>
In-Reply-To: <01BEBB25.A7F332F0.stan@osgroup.com> from "Constantine Shkolny" at Jun 20, 99 02:03:01 pm

next in thread | previous in thread | raw e-mail | index | archive | help
> > this might ease life to those who want to replace ipfw with ipfilter
> > for dummynet or similar things, if nothing else.
> 
> Thank you, Luigi. Could you please help me with some basics?
...

what i do in dummynet is to queue the packet (wheter it comes from
ip_input() or ip_output() makes no difference) in the appropriate data
structure for further processing, and return as if the firewall deleted
the packet.

Subsequently, when processing is done (in dummynet this means some time
has passed and we get a timer interrupt, in your case i suppose your
interrupt service routine would get called in this case), reinvoke the
appropriate routine (p_input() or ip_output()) with the packet
prepended with a header so that it can distinguish the processed packet
from a new one and act differently.

> If would be nice to have another hook point in a proper place _after_
> the re-assembly stage of ip_input(). It would not cause much overhead
> if nobody has a hook installed.

i did not have this problem with dummynet -- if you need the reassembly
first, then probably you have to hook in ip_input() after the
reassembly is done, ie between IP and the upper layer i guess.

	cheers
	luigi
-----------------------------------+-------------------------------------
  Luigi RIZZO, luigi@iet.unipi.it  . Dip. di Ing. dell'Informazione
  http://www.iet.unipi.it/~luigi/  . Universita` di Pisa
  TEL/FAX: +39-050-568.533/522     . via Diotisalvi 2, 56126 PISA (Italy)

		  http://www.iet.unipi.it/~luigi/ngc99/
====  First International Workshop on Networked Group Communication  ====
-----------------------------------+-------------------------------------


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199906210905.LAA21570>