Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 55E892E0038 for ; Thu, 20 Mar 2008 04:48:19 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 03688-01 for ; Thu, 20 Mar 2008 04:48:13 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from ipmail01.adl6.internode.on.net (ipmail01.adl6.internode.on.net [203.16.214.146]) by postgresql.org (Postfix) with ESMTP id 26E6A2E003D for ; Thu, 20 Mar 2008 04:48:15 -0300 (ADT) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AtgFAMiw4UfLevdH/2dsb2JhbACBWqgA X-IronPort-AV: E=Sophos;i="4.25,530,1199626200"; d="scan'208";a="65927674" Received: from ppp247-71.static.internode.on.net (HELO DevBox.local) ([203.122.247.71]) by ipmail01.adl6.internode.on.net with ESMTP; 20 Mar 2008 18:18:12 +1030 Message-ID: <47E216BA.50406@Sheeky.Biz> Date: Thu, 20 Mar 2008 18:18:10 +1030 From: Shane Ambler User-Agent: Thunderbird 2.0.0.12 (Macintosh/20080213) MIME-Version: 1.0 To: Bhella Paramjeet-PFCW67 CC: pgsql-admin@postgresql.org Subject: Re: Postgres database and firewall References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/159 X-Sequence-Number: 28642 Bhella Paramjeet-PFCW67 wrote: > Hi > > > We will be setting up a production postgres database to which an > application will connect through a firewall. Can any one please tell me > if there is any configuration that needs to be done on the postgres > database side for firewall. Is there any documentation that I can refer > to. Any help will be appreciated. > > Thanks > Paramjeet Bhella > > If you are using NAT then you need port forwarding setup on the firewall. If not then you need to make sure it allows the pg traffic through. Your firewall docs will show how to setup that. Default port for pg is 5432 As far as pg config goes the client ip addresses need to be allowed to connect. This is setup in pg_hba.conf see chapter 21 http://www.postgresql.org/docs/8.3/interactive/client-authentication.html For connections over the internet you should configure postgresql with SSL support and use something like - hostssl mydb +usergroup 192.168.1.0/24 md5 The problems arise if you want to allow roaming users that can have varying ip addresses - try to find a solution that doesn't allow any computer on the net to connect. Will you (or can you) have VPN access to the internal network? -- Shane Ambler pgSQL (at) Sheeky (dot) Biz Get Sheeky @ http://Sheeky.Biz