From owner-freebsd-questions@FreeBSD.ORG Tue Jun 10 00:41:22 2003 Return-Path: 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 11C4D37B401 for ; Tue, 10 Jun 2003 00:41:22 -0700 (PDT) Received: from mailer1.trusc.net (sentinel.trusc.net [196.15.149.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id A807343FDF for ; Tue, 10 Jun 2003 00:41:13 -0700 (PDT) (envelope-from leon@trusc.net) Received: from localhost.trusc.net ([127.0.0.1] helo=localhost) by mailer1.trusc.net with esmtp (Exim 4.20) id 19PdlL-0001M3-NM; Tue, 10 Jun 2003 09:41:47 +0200 Received: from mailer1.trusc.net ([127.0.0.1]) by localhost (sentinel.trusc.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 04883-04; Tue, 10 Jun 2003 09:41:36 +0200 (SAST) Received: from godzilla.trusc.net ([196.15.149.67] helo=leon) by mailer1.trusc.net with smtp (Exim 4.20) id 19PdlA-0001Ly-Fm; Tue, 10 Jun 2003 09:41:36 +0200 From: "Leon Botes" To: "'Nathan Nieblas'" Date: Tue, 10 Jun 2003 09:39:50 +0200 Message-ID: <000a01c32f23$7a1b82d0$19fea8c0@trusc.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook CWS, Build 9.0.2416 (9.0.2910.0) X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4925.2800 Importance: Normal In-Reply-To: <001501c32f1f$18da09a0$0200a8c0@riv1nnieblas> X-Virus-Spam-Mime-Extension-Scanned: by Trusc Technologies with Amavisd-New cc: freebsd-questions@freebsd.org Subject: RE: Routing question X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: leon@trusc.net List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Jun 2003 07:41:22 -0000 Thanks for the ideas however i dont think they will work. You see the problem is for example this. A connection from outside on the internet can only see the outside interface 1 - 196.15.149.64/26 hence the request is sent to that interface which is correct. However and heres the problem. All replies from that interface are sent out via outside interface 2 - 172.16.254.0/24 which is the nat interface and default gateway. So what i need to make the machine do is make the machine send any reply back via the same route that is was received on. Can this be done? -----Original Message----- From: Nathan Nieblas [mailto:nnieblas@microtosh.net] Sent: 10 June 2003 09:08 To: leon@trusc.net; freebsd-questions@FreeBSD.ORG Subject: Re: Routing question You can probably get what you want by compiling IPDIVERT and IPFIREWALL into your kernel. Then running some rules, this may or may not be accurate: ipfw add 100 divert 172.16.254.1 ip from 192.168.0.0/24 to any via out2 ipfw add 101 divert 196.15.149.65 ip from 196.15.149.64/26 to any via out1 ipfw add 102 divert 172.16.254.1 ip from 172.16.254.0/24 to any via out2 Anyways, you get the idea.. play with that for awhile let me know if I helped any. You probably only need to use rule 101 or something very similar to it. Regards ----- Original Message ----- From: "Leon Botes" To: Sent: Monday, June 09, 2003 11:18 PM Subject: Routing question I have a box with three interface cards. inside interface - 192.168.0.0/24 outside interface 1 - 196.15.149.64/26 outside interface 2 - 172.16.254.0/24 Inside connects to lan with windows pc's outside 1 permanently connected to isp via wan router with diginet (t1 type line) and is viewable from internet. inside 2 connects to internet via DSl router using nat , connection ip cahnges daily. What i want the box to do is send all outgoing requests that originated from the box or the inside lan out the outside interface 2 which it does by setting default route. However when a connectio originates from internet to the outside 1 interface it must route its reply back via the same route and not via the outside interface 2 which it is doing hence making the box invisible to the outside. PLEASE any suggestions? _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org"