Monday, July 21, 2008

Remote Access in PostgreSQL databases

When we need to allow to someone to access our PostgreSQL database in our machine, we need to put following code in our pg_hba.conf file.

# Allow a user from host 192.168.12.10 to connect to database
# "postgres" if the user's password is correctly supplied.
#
# TYPE DATABASE USER CIDR-ADDRESS METHOD
host postgres all 192.168.12.10/32 md5

This is a useful site regarding that.

http://developer.postgresql.org/pgdocs/postgres/auth-pg-hba-conf.html

No comments: