Received: from localhost (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id B3E6F632CC1 for ; Tue, 3 Feb 2009 22:06:26 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 91625-10 for ; Tue, 3 Feb 2009 22:06:09 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mail.postgresql.org (Postfix) with ESMTP id BFACD632CBD for ; Tue, 3 Feb 2009 22:06:09 -0400 (AST) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1LUX9S-0004ov-Ks for pgsql-admin@postgresql.org; Wed, 04 Feb 2009 02:06:06 +0000 Received: from 77.70.61.39 ([77.70.61.39]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 04 Feb 2009 02:06:06 +0000 Received: from milen by 77.70.61.39 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 04 Feb 2009 02:06:06 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-admin@postgresql.org From: "Milen A. Radev" Subject: Re: How to prevent users from creating tables Date: Wed, 04 Feb 2009 04:05:56 +0200 Lines: 20 Message-ID: References: <20090204005222.GA19588@raf.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 77.70.61.39 User-Agent: Thunderbird 2.0.0.19 (Windows/20081209) In-Reply-To: <20090204005222.GA19588@raf.org> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=1.599 tagged_above=0 required=5 tests=RCVD_IN_DNSWL_LOW=-1, RCVD_NUMERIC_HELO=2.599 X-Spam-Level: * X-Archive-Number: 200902/30 X-Sequence-Number: 31251 raf написа: > hi, > > in my database, normal users can't select, insert, update or > delete anything directly. they can only call functions which > are all security defining functions which give access to the > data. that's the way i like it. > > however, i discovered that normal users can create new > tables in the database. is there any way to prevent this? > i couldn't find any grant/revoke syntax in the doco that > looked relevant. [...] You need to revoke the "CREATE" privilege for the schema(s) in question (http://www.postgresql.org/docs/current/static/sql-grant.html#SQL-GRANT-DESCRIPTION-OBJECTS). -- Milen A. Radev