From owner-freebsd-questions Sun Feb 18 19:41:25 2001 Delivered-To: freebsd-questions@freebsd.org Received: from mta1-rme.xtra.co.nz (mta1-rme.xtra.co.nz [203.96.92.1]) by hub.freebsd.org (Postfix) with ESMTP id 0FA6E37B67D for ; Sun, 18 Feb 2001 19:41:22 -0800 (PST) Received: from vermin.h1 ([210.55.82.216]) by mta1-rme.xtra.co.nz with ESMTP id <20010219034157.LAYT779398.mta1-rme.xtra.co.nz@vermin.h1> for ; Mon, 19 Feb 2001 16:41:57 +1300 Received: from cyclone.h1 ([192.168.1.3]) by vermin.h1 with esmtp (Exim 3.16 #1) id 14UhBk-00006A-00 for freebsd-questions@freebsd.org; Mon, 19 Feb 2001 16:40:36 +1300 Received: from grantjd by cyclone.h1 with local (Exim 3.22 #1 (Debian)) id 14UhCY-0000KF-00 for ; Mon, 19 Feb 2001 16:41:26 +1300 Date: Mon, 19 Feb 2001 16:41:25 +1300 From: James Grant To: freebsd-questions@freebsd.org Subject: natd won't redirect ports. Message-ID: <20010219164125.A1234@cyclone.h1> Mail-Followup-To: James Grant , freebsd-questions@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.12i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi, I've set ipfw and natd up on my firewall machine which has a dial on demand ppp connection using a dynamic ip. Everything works fine, except for this problem I'm having with natd. It just seems to ignore the fact I've told it to redirect a port. Say for example I start natd with the following command line (just for debugging purposes): /sbin/natd -n tun0 -dynamic -same_ports -use_sockets -redirect_port tcp 192.168.1.3:6699 6699 -v The output pertaining to a connection to port 6699 looks like this: In [TCP] [TCP] 202.49.64.124:3433 -> 210.55.82.216:6699 aliased to [TCP] 202.49.64.124:3433 -> 210.55.82.216:6699 Out [TCP] [TCP] 210.55.82.216:6699 -> 202.49.64.124:3433 aliased to [TCP] 210.55.82.216:6699 -> 202.49.64.124:3433 It doesn't redirect it at all!! Hence my napster client just sits there waiting for a connection. But if I specify firewall machine's internet address on the command line like so: /sbin/natd -n tun0 -dynamic -same_ports -use_sockets -redirect_port tcp 192.168.1.3:6699 210.55.82.216:6699 -v ... and I get the following output: In [TCP] [TCP] 202.49.64.124:3450 -> 210.55.82.216:6699 aliased to [TCP] 202.49.64.124:3450 -> 192.168.1.3:6699 Out [TCP] [TCP] 192.168.1.3:6699 -> 202.49.64.124:3450 aliased to [TCP] 210.55.82.216:6699 -> 202.49.64.124:3450 and so it works if I specify the IP on the command line, but that isn't really useful for dial on demand with a dynamic IP. Ideas anyone? -- James. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message