From owner-freebsd-net@FreeBSD.ORG Sat Oct 25 20:06:33 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1FF6716A4B3 for ; Sat, 25 Oct 2003 20:06:33 -0700 (PDT) Received: from imhotep.yuckfou.org (cust.89.117.adsl.cistron.nl [195.64.89.117]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8241543FBF for ; Sat, 25 Oct 2003 20:06:31 -0700 (PDT) (envelope-from nivo+sender+8eb026@yuckfou.org) Received: from localhost (localhost [127.0.0.1]) by imhotep.yuckfou.org (Postfix) with ESMTP id 34EF3B0 for ; Sun, 26 Oct 2003 03:35:08 +0100 (CET) Received: from imhotep.yuckfou.org ([127.0.0.1]) by localhost (imhotep.yuckfou.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 39283-09 for ; Sun, 26 Oct 2003 03:35:06 +0100 (CET) Received: from localhost.yuckfou.org (localhost [IPv6:::1]) by imhotep.yuckfou.org (Postfix) with ESMTP id 959B6A4 for ; Sun, 26 Oct 2003 03:35:05 +0100 (CET) Received: from yuckfou.org (turbata-xp [192.168.2.236]) by localhost.yuckfou.org (tmda-ofmipd) with ESMTP; Sun, 26 Oct 2003 03:34:58 +0100 (CET) Message-ID: <3F9B32D2.7080804@yuckfou.org> Date: Sun, 26 Oct 2003 03:34:58 +0100 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5b) Gecko/20030912 Thunderbird/0.3a X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-net@freebsd.org References: <1067128348.400238.16844.nullmailer@cicuta.babolo.ru> In-Reply-To: <1067128348.400238.16844.nullmailer@cicuta.babolo.ru> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit From: Nils Vogels X-Delivery-Agent: TMDA/0.86 (Venetian Way) X-TMDA-Fingerprint: 7399RBAdoKjZi9vgBjezt0FOQBM X-Virus-Scanned: by amavisd-new at yuckfou.org Subject: Re: Reverse IP NAT to secondary IP address X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Nils Vogels List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Oct 2003 03:06:33 -0000 "."@babolo.ru wrote: >configure port with SNMP-server as 192.168.0.17/30 for example >instead 192.168.2.1/24, and >sysctl net.link.ether.inet.proxyall=1 > >and configure SNMP-server as 192.168.0.18/24 > >If you can change mask of SNMP-server, you can >use 192.168.0/24 and 192.168.1/24 on gateway >and 192.168.0/25 on SNMP-server. > >No NAT is needed. > > I just tried this, but unfortunately, the same thing happens as with ipfilter: The primary address of the interface ed0 on the gateway (the public adress) is used to forward the arp request. Taken from a dump on the gateay, when attempting telnet: Incoming on rl0: 03:35:05.867883 192.168.0.2.1511 > 192.168.2.2.23: S 1377718084:1377718084(0) win 57344 (DF) [tos 0x10] Outgoing on ed0: 03:35:05.868333 195.0.0.1.15009 > 192.168.2.2.23: S 1377718084:1377718084(0) win 57344 (DF) [tos 0x10] Since 195.0.0.1 (obviously obfuscated) does not fall within the subnet the 192.168.2.2 box is on, there will never be a reply from the 192.168.2.2 box. ARP proxying goes fine, on the WWW box, I can see the proxied reply coming from my gateway for the 192.168.1.1 address ..... Can anyone tell me, how I can make the box use the secondary address (alias) automatically for forwarding the telnet session? Could it be that since the gateway is running many-to-one NAT as well, this is conflicting ? Greetings, Nils.