Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Sep 2003 00:03:47 -0700
From:      Luigi Rizzo <rizzo@icir.org>
To:        Josh Brooks <user@mail.econolodgetulsa.com>
Cc:        freebsd-net@freebsd.org
Subject:   Re: how do I delete just one ipfw rule ?
Message-ID:  <20030909000347.A90081@xorpc.icir.org>
In-Reply-To: <20030908234910.H77579-100000@mail.econolodgetulsa.com>; from user@mail.econolodgetulsa.com on Mon, Sep 08, 2003 at 11:50:53PM -0700
References:  <20030908234910.H77579-100000@mail.econolodgetulsa.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Sep 08, 2003 at 11:50:53PM -0700, Josh Brooks wrote:
> 
> Hi,
> 
> If I create two ipfw rules with the same ID:
> 
> ipfw add 00022 deny ip from x to y
> ipfw add 00022 allow ip from z to b
> 
> they will both be there, and both work ... but is it possible to remove
> just one of them wihout removing the other ?  Right now I am doing a hack
> with a ";"
> 
> ipfw del 00022 ; ipfw add 00022 allow ip from z to b
> 
> which removes both, and re-adds the one I want, but if the list gets more
> complicated than a few, this is really bad.
> 
> So is it possible to remove just one ipfw rule from a list of same-index
> rules ?

no, it is not possible to delete them -- you have no way to tell
which rule to delete when multiple rules share the same number.

	cheers
	luigi



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