Re: Restricting user access to databases - Mailing list pgsql-admin

From Jared Sulem
Subject Re: Restricting user access to databases
Date
Msg-id 3AE58C70.2040503@sulem.freeserve.co.uk
Whole thread Raw
In response to Restricting user access to databases  (Jared Sulem <jsulem@sulem.freeserve.co.uk>)
List pgsql-admin
Jared Sulem wrote:

> Is there anyway to make PostgreSQL automatically only grant access to
> databases by their owners, and preferably database superusers, rather
> than making lots of pg_hba.conf entries and password files?

Just had an idea.  Another token could be added to the pg_hba.conf file:
'owner'.  Then the line:

host
all
192.168.3.0
255.255.255.0
password owner

Would only allow users that owned the database they were trying to
access to login.  'owner' being like a virtual file containing only the
owner's name of the database, that the user is trying to access.

(Or is there already a way to easily do this?)

Jared




pgsql-admin by date:

Previous
From: Jared Sulem
Date:
Subject: Restricting user access to databases
Next
From: Jared Sulem
Date:
Subject: Re: Restricting user access to databases