From owner-freebsd-ipfw@FreeBSD.ORG Tue Aug 24 20:19:59 2004 Return-Path: Delivered-To: freebsd-ipfw@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9D02F16A4CE; Tue, 24 Aug 2004 20:19:59 +0000 (GMT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8F63D43D53; Tue, 24 Aug 2004 20:19:59 +0000 (GMT) (envelope-from csjp@freebsd.org) Received: from freefall.freebsd.org (csjp@localhost [127.0.0.1]) i7OKJxjR062439; Tue, 24 Aug 2004 20:19:59 GMT (envelope-from csjp@freebsd.org) Received: (from csjp@localhost) by freefall.freebsd.org (8.12.11/8.12.11/Submit) id i7OKJxcw062438; Tue, 24 Aug 2004 20:19:59 GMT (envelope-from csjp@freebsd.org) X-Authentication-Warning: freefall.freebsd.org: csjp set sender to csjp@freebsd.org using -f Date: Tue, 24 Aug 2004 20:19:59 +0000 From: "Christian S.J. Peron" To: Andre Oppermann Message-ID: <20040824201958.GA61912@freefall.freebsd.org> References: <412B8799.4020808@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <412B8799.4020808@freebsd.org> User-Agent: Mutt/1.4.1i cc: myself@rojer.pp.ru cc: ipfw@freebsd.org Subject: Re: Could you have a look at kern/63961 X-BeenThere: freebsd-ipfw@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: IPFW Technical Discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Aug 2004 20:19:59 -0000 Hey Andre, I took a quick look at the PR and I dont think this is a bug. If you want to match setup packets for TCP connections it does work, but only if the connection has a PCB associated with it. For instance, outgoing setup would have a PCB associated with it, so ipfw could match on that: dev0# ipfw show 00400 1 64 count tcp from any to any dst-port 4296 setup uid csjp It should be noted that all the "setup" keyword does is set the O_TCPFLAGS opcode and set the operand to TH_SYN for SYN packets. I dont think Incoming TCP connection requests would not have a PCB associated with it, so there is no-way that ipfw can look up the credential associated with it. However the UID negation problem looks like it could be a bug either in how ipfw(8) reports the rule or how the kernel is processing it. In either case I will look into it. -- Christian S.J. Peron csjp@FreeBSD.ORG FreeBSD Committer