From owner-freebsd-questions Fri Jul 12 17:58:57 2002 Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8E0D337B400 for ; Fri, 12 Jul 2002 17:58:54 -0700 (PDT) Received: from cactus.fi.uba.ar (cactus.fi.uba.ar [157.92.49.108]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4E15643E6A for ; Fri, 12 Jul 2002 17:58:53 -0700 (PDT) (envelope-from fgleiser@cactus.fi.uba.ar) Received: from localhost (localhost [127.0.0.1]) by cactus.fi.uba.ar (8.11.6/8.11.6) with ESMTP id g6D0trH05708; Fri, 12 Jul 2002 21:55:54 -0300 (ART) (envelope-from fgleiser@cactus.fi.uba.ar) Date: Fri, 12 Jul 2002 21:55:53 -0300 (ART) From: Fernando Gleiser X-X-Sender: To: Carlos Carnero Cc: FreeBSD Questions Subject: Re: Excluding from IP Filter redirection In-Reply-To: <20020712201727.3179.qmail@web21412.mail.yahoo.com> Message-ID: <20020712212706.S624-100000@localhost> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, 12 Jul 2002, Carlos Carnero wrote: > Hi, > > I have already set up IP Filter and ipnat, together > with Squid I have created a "transparent" proxy. The > syntax of the ipnat rule is: > > rdr fxp0 0.0.0.0/0 port 80 -> 192.168.4.1 port > 3128 > > being fxp0 my internal interface, and 192.168.4.1 the > internal IP number of the gateway. So, right now > everybody is directed to Squid :) > > However, is there a way to exclude a couple of > internal IP numbers from being redirected? Just exclude them from the rdr rule. The easiest way is to place the excluded IPs in a different range than the redirected ones. Put a 'rdr' rule for the later, and the former ones won't be redirected. For example, if your internal net is 192.168.4.0/24, place a privilleged block in the lower 64 IPs and the rdr rule becomes: rdr fxp0 192.168.4.64/26 -> 192.168.4.1 port 3128 rdr fxp0 192.168.4.128/25 -> 192.168.4.1 port 3128 That is, the lower 64 addresses won't be redirected, and everything else will. Hope this helps. Fer > > Best regards, > Carlos. > > __________________________________________________ > Do You Yahoo!? > Sign up for SBC Yahoo! Dial - First Month Free > http://sbc.yahoo.com > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message