pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Shane Ambler <pgsql@Sheeky.Biz>
To: Bhella Paramjeet-PFCW67 <PBhella@Motorola.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Postgres database and firewall
Date: Thu, 20 Mar 2008 18:18:10 +1030
Message-ID: <47E216BA.50406@Sheeky.Biz> (raw)
In-Reply-To: <C84662912D280D4AB5C50100A100F0C5033824CB@ct11exm61.ds.mot.com>
References: <C84662912D280D4AB5C50100A100F0C5033824CB@ct11exm61.ds.mot.com>

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



view thread (4+ messages)  latest in thread

Message-ID: <47E216BA.50406@Sheeky.Biz>
Permalink:  ../47E216BA.50406@Sheeky.Biz/
Also on:    postgresql.org/message-id/47E216BA.50406@Sheeky.Biz

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: pgsql@Sheeky.Biz, PBhella@Motorola.com
  Subject: Re: Postgres database and firewall
  In-Reply-To: <47E216BA.50406@Sheeky.Biz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox