BUG #5609: Exclusive Locks & Permission

Поиск
Список
Период
Сортировка
От Rob Brucks
Тема BUG #5609: Exclusive Locks & Permission
Дата
Msg-id 201008091913.o79JDUPh016674@wwwmaster.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #5609: Exclusive Locks & Permission  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
The following bug has been logged online:

Bug reference:      5609
Logged by:          Rob Brucks
Email address:      rob.brucks@rackspace.com
PostgreSQL version: 8.3.7
Operating system:   Ubuntu 8.04
Description:        Exclusive Locks & Permission
Details:

If a user that does not have permission to alter a table issues an alter he
acquires an exclusive lock BEFORE permission is checked and an error is
issued.

This causes concurrency problems since the unprivileged user causes other
threads to wait while it attempts to acquire an exclusive lock, only to have
it ultimately fail.

The user's permissions need to be checked before requesting an exclusive
lock on the table for the alter.

To re-create:
psql -U postgres -d postgres
postgres=# CREATE ROLE nobody NOSUPERUSER NOCREATEDB NOCREATEROLE INHERIT
LOGIN;
postgres=# CREATE TABLE tab1 (a int);
postgres=# REVOKE ALL ON tab1

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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: postgres 9.0 beta libpq empty binary array error
Следующее
От: Robert Haas
Дата:
Сообщение: Re: BUG #5587: Installer non-default file association problem