From owner-freebsd-ipfw Mon Jul 29 13: 8:57 2002 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 19DF537B401 for ; Mon, 29 Jul 2002 13:08:56 -0700 (PDT) Received: from chello.barmentlo.net (a124038.upc-a.chello.nl [62.163.124.38]) by mx1.FreeBSD.org (Postfix) with ESMTP id 51A4F43E42 for ; Mon, 29 Jul 2002 13:08:54 -0700 (PDT) (envelope-from patrick@barmentlo.nl) Received: from gateway.barmentlo.net (gateway [10.0.0.1]) by chello.barmentlo.net (8.12.5/8.12.3) with ESMTP id g6TK7lmi089312; Mon, 29 Jul 2002 22:07:47 +0200 (CEST) (envelope-from patrick@barmentlo.nl) Received: from localhost (pbm@localhost) by gateway.barmentlo.net (8.12.5/8.12.3/Submit) with ESMTP id g6TK7gKD089309; Mon, 29 Jul 2002 22:07:46 +0200 (CEST) (envelope-from patrick@barmentlo.nl) X-Authentication-Warning: gateway.barmentlo.net: pbm owned process doing -bs Date: Mon, 29 Jul 2002 22:07:42 +0200 (CEST) From: patrick X-X-Sender: pbm@gateway.barmentlo.net To: Mike Dewhirst Cc: freebsd-ipfw@FreeBSD.ORG Subject: Re: divert a port to another ip In-Reply-To: <3D45740A.2000704@devzerog.com> Message-ID: <20020729220304.K88943-100000@gateway.barmentlo.net> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-ipfw@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, 29 Jul 2002, Mike Dewhirst wrote: > If I want to divert all requests on a certain port to another ip address > and another port, e.g. > > 80.0.0.123:666 --> 192.10.10.5:22 > I have this rule that works: > divert 8668 ip from any to any via xl1 you should extend this command with -redirect_port tcp x.x.x.x:666 x.x.x.x:22 if you need more, just extend the command again. you will see the rules back with the ipfw show command next to your 'regular' divert rule. check man natd, you can use a config file in order to prevent your command to become really long. grtz patrick -- Patrick Barmentlo - Unix System Administrator To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ipfw" in the body of the message