Skip site navigation (1) Skip section navigation (2)

Re: Best practice running a shared DB hosting server

From: "Scott Marlowe" <scott(dot)marlowe(at)gmail(dot)com>
To: "Thomas Jacob" <jacob(at)internet24(dot)de>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: Best practice running a shared DB hosting server
Date: 2008-08-13 14:57:39
Message-ID: dcc563d10808130757o45cdeb45jaa87cc09d0bdd837@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-admin
On Wed, Aug 13, 2008 at 7:44 AM, Thomas Jacob <jacob(at)internet24(dot)de> wrote:
> Hello List,
>
> I was wondering if there is something like
> a best practice document for running
> PostgreSQL (probably 8.3.3) securely in a shared
> Web+DB hosting environment, where different
> people without any administrative relationship
> between them may run their databases on
> the same server.

Well, databases are designed to be accessed by people you trust to not
do really stupid things that can affect the other users.

I'd set up a db per user with pg_hba.conf set to only allow them to
log into the db of their own name.

> I am particularly interested in the
> role, permission and schema layout.

Each user = a new database. Let them do what they want to in there.

> Also I'm worried about the amount of information
> available to ordinary DB users. For instance,
> without revoking access to pg_catalog from
> PUBLIC all users can see the usernames,
> database names etc. of all other users. But
> revoking the right from pg_catalog doesn't
> seem to be an option, as this breaks
> several features of the psql utility and probably
> other things.

Hiding such things would only be security via obscurity and would
accomplish exactly nothing..  Actually keeping people from logging
into another user's database is much more important.  that you can do
with pg_hba.conf.

In response to

Responses

pgsql-admin by date

Next:From: Thomas JacobDate: 2008-08-13 15:48:10
Subject: Re: Best practice running a shared DB hosting server
Previous:From: Thomas JacobDate: 2008-08-13 13:44:57
Subject: Best practice running a shared DB hosting server

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group