X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 26FDB9DCA5E for ; Mon, 27 Feb 2006 14:29:40 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 67941-06 for ; Mon, 27 Feb 2006 14:29:39 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from wolff.to (wolff.to [66.93.197.194]) by postgresql.org (Postfix) with SMTP id E2A229DC9A6 for ; Mon, 27 Feb 2006 14:29:37 -0400 (AST) Received: (qmail 27385 invoked by uid 500); 27 Feb 2006 18:39:30 -0000 Date: Mon, 27 Feb 2006 12:39:29 -0600 From: Bruno Wolff III To: Dayo Johnson Cc: pgsql-admin@postgresql.org Subject: Re: Priviliges and Roles Message-ID: <20060227183929.GA24041@wolff.to> Mail-Followup-To: Bruno Wolff III , Dayo Johnson , pgsql-admin@postgresql.org References: <4402EC0C.9030903@cleanjohn.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4402EC0C.9030903@cleanjohn.net> User-Agent: Mutt/1.4.2.1i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.098 required=5 tests=[AWL=0.098] X-Spam-Score: 0.098 X-Spam-Level: X-Archive-Number: 200602/320 X-Sequence-Number: 20741 On Mon, Feb 27, 2006 at 12:09:48 +0000, Dayo Johnson wrote: > Hello, > > Is it possible to do the following: > Disallow permission to write to a table (either by UPDATE or INSERT) but > allow EXECUTE permission on a Function that writes to the table ? > > The reason I want to do this is so that I can perform certain checks on > the data that is being written before I allow it to be written. You can use SECURITY DEFINER functions to do this. Those functions run with the access rights of the function creator, rather than the executor.