From owner-freebsd-net@FreeBSD.ORG Tue Jun 28 10:38:09 2005 Return-Path: X-Original-To: freebsd-net@freebsd.org Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5540916A41C for ; Tue, 28 Jun 2005 10:38:09 +0000 (GMT) (envelope-from max@love2party.net) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.187]) by mx1.FreeBSD.org (Postfix) with ESMTP id DBC9443D1D for ; Tue, 28 Jun 2005 10:38:08 +0000 (GMT) (envelope-from max@love2party.net) Received: from p54A3E06D.dip.t-dialin.net [84.163.224.109] (helo=donor.laier.local) by mrelayeu.kundenserver.de with ESMTP (Nemesis), id 0ML2Dk-1DnDTh3L2I-0005Vr; Tue, 28 Jun 2005 12:38:05 +0200 From: Max Laier To: Jeremie Le Hen Date: Tue, 28 Jun 2005 12:37:56 +0200 User-Agent: KMail/1.8 References: <42C0DB3B.6000606@elischer.org> <200506281147.13299.max@love2party.net> <20050628102728.GZ1283@obiwan.tataz.chchile.org> In-Reply-To: <20050628102728.GZ1283@obiwan.tataz.chchile.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1220710.B1xTd7uyAy"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200506281238.04373.max@love2party.net> X-Provags-ID: kundenserver.de abuse@kundenserver.de login:61c499deaeeba3ba5be80f48ecc83056 Cc: freebsd-net@freebsd.org, Milan Obuch , Julian Elischer Subject: Re: Julian's netowrking challenge 2005 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Jun 2005 10:38:09 -0000 --nextPart1220710.B1xTd7uyAy Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On Tuesday 28 June 2005 12:27, Jeremie Le Hen wrote: > > Wouldn't a more general approach be better. e.g. a way to "tag" a pack= et > > before it is sent to divert and a matching tag-lookup that can do furth= er > > action. This would make it very easy to do all kinds of stuff that nee= ds > > to know the original address instead of the translated one while avoidi= ng > > code duplication. > > Having the possibility to tag a packet would be worth indeed. But I > think that Milan wants to bring network stack virtualization in > newer release of FreeBSD IIUC. This would be, IMO, a great improvement > of FreeBSD networking, although I'm pretty sure this would make Netgraph > people react a bit ;-). Stack virtualization is independent of this. All I am trying to say here, = is=20 that I think it is better to have a general mechanism to do thing like that= ,=20 instead of a special solution for fwd (i.e. set-nexthop). > > pf does something along these lines in case you are looking for > > references. > > Would it be possible to share this tag among pf and ipfw ? Sure, it's a simple mbuf tag with a (at this point) 16bit cookie. The=20 downside of this approach is that you need to malloc the tag, but on the=20 other hand it's even more complicated for set-nexthop where you need to=20 allocate a route and maybe even hold it for some time and make sure you=20 properly GC it ... tags seem way simpler to me. =2D-=20 /"\ Best regards, | mlaier@freebsd.org \ / Max Laier | ICQ #67774661 X http://pf4freebsd.love2party.net/ | mlaier@EFnet / \ ASCII Ribbon Campaign | Against HTML Mail and News --nextPart1220710.B1xTd7uyAy Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (FreeBSD) iD8DBQBCwSiMXyyEoT62BG0RAqauAJ445qA9Rap+1yR7juuKnVc5DaunEQCaAphU +QKllFQ3kvpbHomEnlFqvc4= =Py3w -----END PGP SIGNATURE----- --nextPart1220710.B1xTd7uyAy--