Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 1F4566324CE for ; Tue, 7 Jul 2009 14:10:47 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 54683-07 for ; Tue, 7 Jul 2009 14:10:33 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-fx0-f205.google.com (mail-fx0-f205.google.com [209.85.220.205]) by mail.postgresql.org (Postfix) with ESMTP id AF7AA632853 for ; Tue, 7 Jul 2009 14:10:34 -0300 (ADT) Received: by fxm1 with SMTP id 1so949848fxm.19 for ; Tue, 07 Jul 2009 10:10:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:from:date:x-google-sender-auth:message-id:subject:to:cc :content-type:content-transfer-encoding; bh=M+47IyuLu1qeU6uh9Tbm89ZvrxZtf0ShQ5jy5OHyCfw=; b=GXZcSy78z3oY5MnUeC9zLMU9u0Pkzy1hBCCBVlhmN2b7Khq8GhTT1mVk0xpb3wzlkK 7SnTgvg7eaooanNYnX6RT/zcpGUqV+bT6TUFrGXTjl6zbxRV9qgapwLQJEFYFkgUu//P rs13i7+sxJYLK7UZYSVlquHUDNoc38zdB/yd0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :content-transfer-encoding; b=tjyATH5kikWDtF5xgdTqXvC99O2BfdygbUmo8bcpH7Fxf5TeLzIIjxQ1YbJ3vDmz4r MH10OPKfXeGqFUKOnqRUY5Zp2ka6CE9U7GTkSXSjqlhduFRm/0OaYkvisIAptYGijk1Q ZtJMbx+uEiqjv3f96gLkMo1PUXmRbqz7HHZ/o= MIME-Version: 1.0 Received: by 10.103.197.14 with SMTP id z14mr3530351mup.1.1246986633216; Tue, 07 Jul 2009 10:10:33 -0700 (PDT) In-Reply-To: <7045.1246979795@sss.pgh.pa.us> References: <4A37BF63.50008@pjmodos.net> <4A37E122.8070303@pjmodos.net> <4A38A956.8080600@pjmodos.net> <4A4DE104.8090605@pjmodos.net> <1246963514.3874.156.camel@ebony.2ndQuadrant> <7045.1246979795@sss.pgh.pa.us> From: Greg Stark Date: Tue, 7 Jul 2009 18:10:13 +0100 X-Google-Sender-Auth: ea5cbb45b731e5c8 Message-ID: <407d949e0907071010v71e2bafam6d5fc6ae56e2fed5@mail.gmail.com> Subject: Re: GRANT ON ALL IN schema To: Tom Lane Cc: Simon Riggs , Petr Jelinek , PostgreSQL-development Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200907/404 X-Sequence-Number: 141026 On Tue, Jul 7, 2009 at 4:16 PM, Tom Lane wrote: > >> (I'm sure we can do something intelligent with privileges that don't >> apply to all object types rather than just fail. e.g. UPDATE privilege >> should be same as USAGE on a sequence.) > > Anything you do in that line will be an ugly kluge, and will tend to > encourage insecure over-granting of privileges (ie GRANT ALL ON ALL > OBJECTS ... what's the point of using permissions at all then?) That seems a bit pessimistic. While I disagree with Simon's rule I think you can get plenty of mileage out of a more conservative rule of just granting the privilege to all objects for which that privilege is defined. Especially when you consider that we allow listing multiple privileges in a single command. -- greg http://mit.edu/~gsstark/resume.pdf