From owner-freebsd-security@FreeBSD.ORG Tue Jun 3 07:36:24 2003 Return-Path: Delivered-To: freebsd-security@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 54D1537B401 for ; Tue, 3 Jun 2003 07:36:24 -0700 (PDT) Received: from mail.secureworks.net (mail.secureworks.net [209.101.212.155]) by mx1.FreeBSD.org (Postfix) with SMTP id 7485043FA3 for ; Tue, 3 Jun 2003 07:36:23 -0700 (PDT) (envelope-from mdg@secureworks.net) Received: (qmail 750 invoked from network); 3 Jun 2003 14:34:03 -0000 Received: from unknown (HELO HOST-192-168-17-31.internal.secureworks.net) (209.101.212.253) by mail.secureworks.net with SMTP; 3 Jun 2003 14:34:03 -0000 Date: Tue, 3 Jun 2003 10:36:20 -0400 (EDT) From: Matthew George X-X-Sender: mdg@localhost To: Paulo Roberto In-Reply-To: <20030602232710.20360.qmail@web14908.mail.yahoo.com> Message-ID: <20030603103402.A40213@localhost> References: <20030602232710.20360.qmail@web14908.mail.yahoo.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: freebsd-security@freebsd.org Subject: Re: Packet flow through IPFW+IPF+IPNAT ? X-BeenThere: freebsd-security@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Security issues [members-only posting] List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Jun 2003 14:36:24 -0000 On Mon, 2 Jun 2003, Paulo Roberto wrote: > --- Fernando Gleiser wrote: > > On Mon, 2 Jun 2003, Vlad GALU wrote: > > Or, in other words, IPF always 'sees' the real IPs, not the NATed > > ones. > > Is it also true for IPFW? Does the rules apply always to the real > addresses instead of the natted ones? So why does the "divert natd" > rule must be the first rule in ipfw? (in rc.firewall it is rule 00050). > Is the packet reinserted on the queue, or it just wait a "pass" rule so > it can be put on rule #00050 and go on? > > TIA > > Paulo Roberto > It depends on where the divert rule is. If it's the first rule, then yes. You can do pre-nat filtering by placing rules before the divert if you want. I typically do all my RFC1918 et al. filtering on my external interfaces pre-nat. -- Matthew George SecureWorks Technical Operations