From owner-freebsd-net@FreeBSD.ORG Wed Jan 18 15:01:33 2006 Return-Path: X-Original-To: freebsd-net@FreeBSD.org 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 F3A5016A41F for ; Wed, 18 Jan 2006 15:01:32 +0000 (GMT) (envelope-from glebius@FreeBSD.org) Received: from cell.sick.ru (cell.sick.ru [217.72.144.68]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3ED9043D49 for ; Wed, 18 Jan 2006 15:01:32 +0000 (GMT) (envelope-from glebius@FreeBSD.org) Received: from cell.sick.ru (glebius@localhost [127.0.0.1]) by cell.sick.ru (8.13.3/8.13.3) with ESMTP id k0IF1HqH085431 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 18 Jan 2006 18:01:17 +0300 (MSK) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.sick.ru (8.13.3/8.13.1/Submit) id k0IF1HZD085430; Wed, 18 Jan 2006 18:01:17 +0300 (MSK) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.sick.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Wed, 18 Jan 2006 18:01:17 +0300 From: Gleb Smirnoff To: Tiago Cruz Message-ID: <20060118150117.GT83922@FreeBSD.org> Mail-Followup-To: Gleb Smirnoff , Tiago Cruz , "freebsd-net@FreeBSD.org" References: <1137520320.15943.92.camel@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <1137520320.15943.92.camel@localhost.localdomain> User-Agent: Mutt/1.5.6i Cc: "freebsd-net@FreeBSD.org" Subject: Re: MPD and client behind firewall X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jan 2006 15:01:33 -0000 On Tue, Jan 17, 2006 at 03:52:00PM -0200, Tiago Cruz wrote: T> I have a FreeBSD 6.0 running MPD server 3.18_3. T> The MPD server works very good when I has _direct_ connected by T> Internet. T> T> My problem is with one _client_ (Win XP) behind NAT from iptables. I T> have to do some in my PF? T> T> In this case, I've tried do this (in iptables from client): T> T> # Allow forwarding from inside to out and vice versa T> iptables -A FORWARD -i $INTINT -s $LOCALNETWORK -j ACCEPT T> iptables -A FORWARD -o $INTINT -d $LOCALNETWORK -j ACCEPT T> T> # Allow pptpd connections (port 1723) T> iptables -t nat -A PREROUTING -i $EXTINT -p TCP --sport $PUBLICPORTS T> --dport 1723 -j ACCEPT T> iptables -t nat -A OUTPUT -o $EXTINT -p 47 -j ACCEPT T> iptables -A OUTPUT -o $EXTINT -p 47 -j ACCEPT T> iptables -A INPUT -i $EXTINT -p 47 -j ACCEPT T> T> But still don't woking. Somebody can help me? Follow the mpd.log: Masquarading GRE protocol, which is used by PPTP as transport, isn't simple. Not all NATs can do this. If you are going to server a lot of clients connecting from random places in the world, then you will face this problem time to time. Can you check whether iptables support NATing PPTP? -- Totus tuus, Glebius. GLEBIUS-RIPN GLEB-RIPE