Re: pg_hba.conf - Allow All Connections Over TCP/IP Networks

From: John R Pierce <pierce(at)hogranch(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: pg_hba.conf - Allow All Connections Over TCP/IP Networks
Date: 2010-02-15 22:38:54
Message-ID: 4B79CCFE.5040105@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Wang, Mary Y wrote:
> Hi,
>
> I'd like to allow all connections over TCP/IP networks. So could I just add the following line to the pg_hba.conf in the $PGDATA directory?
> "host all * trust"
>
> The database server is located inside a firewall.
>
>

host all all 0.0.0.0/0 trust

or

host all all 192.168.0.0/24 trust

(or whatever your subnet is in CIDR style network/size notation)

of course, you also need

listen_address = '*'

in your postgresql.conf so the server is listening on all network interfaces

Personally, I still prefer to use md5 rather than trust and use password
authentication for LAN connections.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Peter Geoghegan 2010-02-16 00:04:22 Having a plpgsql function return multiple rows that indicate its progress in a cursor like fashion
Previous Message Wang, Mary Y 2010-02-15 21:56:54 pg_hba.conf - Allow All Connections Over TCP/IP Networks