From: Tom Lane <tgl@sss.pgh.pa.us>
To: Heni Lolov <hal_bg@yahoo.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: CREATE TABLE in PUBLIC schema
Date: Wed, 13 Nov 2002 12:47:22 -0500
Message-ID: <23647.1037209642@sss.pgh.pa.us> (raw)
In-Reply-To: <20021113155842.41664.qmail@web21001.mail.yahoo.com>
References: <20021113155842.41664.qmail@web21001.mail.yahoo.com>
Heni Lolov <hal_bg@yahoo.com> writes:
> ive tried :
> revoke all ON schema public from hal;
> but does not work. Why?
You'd need to revoke the permissions from PUBLIC; they were never granted
specifically to hal, thus the above revoke is a no-op.
Don't forget to revoke CREATE at the database level, too, else a user
can just create his own schema. Perhaps also revoke TEMP, depending on
whether you'd like to forbid temporary tables as well.
In short, something like
revoke create on schema public from public;
revoke create,temp on database mydb from public;
should give you a database in which users can't create anything.
regards, tom lane
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, hal_bg@yahoo.com
Subject: Re: CREATE TABLE in PUBLIC schema
In-Reply-To: <23647.1037209642@sss.pgh.pa.us>
References: <20021113155842.41664.qmail@web21001.mail.yahoo.com> <23647.1037209642@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox