Re: CREATE USER and pg_user

Поиск
Список
Период
Сортировка
От Jim C. Nasby
Тема Re: CREATE USER and pg_user
Дата
Msg-id 20050822185909.GX95876@pervasive.com
обсуждение исходный текст
Ответ на Re: CREATE USER and pg_user  (Bruno Wolff III <bruno@wolff.to>)
Ответы Re: CREATE USER and pg_user  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Fri, Aug 12, 2005 at 08:55:09AM -0500, Bruno Wolff III wrote:
> On Fri, Aug 12, 2005 at 18:11:54 +0800,
>   William ZHANG <uniware@zedware.org> wrote:
> > "create user foo with createdb" will create a user with createdb privilege.
> > "create user bar with createuser" will create s superuser who can createdb,
> > createuser, and update system catalog.
> > 
> > Why not change the option "createuser" to "superuser", or do something
> > to make is easier to understand?
> 
> Currently being able to create users is effectively the same as having
> superuser privileges, because if you weren't already a superuser, you
> could just create one to get that access.
> Recently there was some discussion about having a createuser ability that
> only allowed one to create nonsuperuser accounts. From the development
> docs it looks like this is going to be in 8.1. However it looks like
> CREATEUSER privilege will continue to be an alias for super user access.
> I didn't notice a documentation update for the createuser program and
> don't know if it will take the new keywords or not.
> For more information take a look at the CREATE ROLE command in the
> developer docs.

ISTM that it's a bug to be able to assign permissions that you don't
yourself have. In this case, if you have CREATEROLE but not SUPERUSER,
then you should be able to create roles, but not ones that have
SUPERUSER status. If this isn't how it currently works then there should
be a big warning under CREATEROLE.
-- 
Jim C. Nasby, Sr. Engineering Consultant      jnasby@pervasive.com
Pervasive Software        http://pervasive.com        512-569-9461


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Missing CONCURRENT VACUUM (Was: Release notes for
Следующее
От: Robert Treat
Дата:
Сообщение: Re: Sleep functions