From owner-freebsd-bugs Sat Mar 23 18:50: 6 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 15FB737B417 for ; Sat, 23 Mar 2002 18:50:03 -0800 (PST) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g2O2o3s84693; Sat, 23 Mar 2002 18:50:03 -0800 (PST) (envelope-from gnats) Date: Sat, 23 Mar 2002 18:50:03 -0800 (PST) Message-Id: <200203240250.g2O2o3s84693@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: "Crist J. Clark" Subject: Re: conf/36230: ipfw traffic shaper with DHCP env. Reply-To: "Crist J. Clark" Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR conf/36230; it has been noted by GNATS. From: "Crist J. Clark" To: Alex de Kruijff Cc: freebsd-gnats-submit@FreeBSD.ORG Subject: Re: conf/36230: ipfw traffic shaper with DHCP env. Date: Sat, 23 Mar 2002 18:42:51 -0800 On Sat, Mar 23, 2002 at 06:34:03AM -0800, Alex de Kruijff wrote: [snip] > I like to run a ipfw traffic shaper on a network with a DHCP server. The DHCP server updates the DNS with a given hostname (+ suffix). The ip-address the client receives can change in time but the hostname do not. The ipfw rules however keep the old values resulting in a rules that do not apply. > >How-To-Repeat: > # add alex to the DNS (nomaly you will let the DHCP do this for you) > > ipfw add 100 pipe 1 ip from alex to any via ed0 > ipfw add 200 pipe 2 ip from any to alex via ed0 > > # change the ip address of the host alex. > >Fix: > Save the URL, if given, instead of the ip-address. How often do you check that the hostname to IP address mapping has changed? For every packet? Way too expensive. Every minute? Every five minutes? Why not just run a cron job to update your rules then? I don't see a practical way to implement this, do you? -- Crist J. Clark | cjclark@alum.mit.edu | cjclark@jhu.edu http://people.freebsd.org/~cjc/ | cjc@freebsd.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message