Re: CREATE DATABASE foo OWNER bar - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: CREATE DATABASE foo OWNER bar
Date
Msg-id 20070416141235.GD5658@alvh.no-ip.org
Whole thread Raw
In response to CREATE DATABASE foo OWNER bar  ("Larry Rosenman" <ler@lerctr.org>)
Responses Re: CREATE DATABASE foo OWNER bar
Re: CREATE DATABASE foo OWNER bar
List pgsql-hackers
Larry Rosenman wrote:
> Greetings,
>     I think I found a bug, or at least a POLA violation.  At work, I created
> a user that is NOT a superuser, nor can that user create databases.  When I
> did a create database foo owner bar, all the schemas are set to be owned by
> the superuser that created the database, not the database owner.
> 
>     Shouldn't everything that is in the DB be owned by the purported owner?

Right.  This is on TODO:

%Set proper permissions on non-system schemas during db creation

Currently all schemas are owned by the super-user because they are copied from
the template1 database. 


I note it is marked with a %, but it's clearly not easy at all.

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


pgsql-hackers by date:

Previous
From: Larry Rosenman
Date:
Subject: Re: CREATE DATABASE foo OWNER bar
Next
From: Andrew Dunstan
Date:
Subject: Re: CREATE DATABASE foo OWNER bar