X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 352C7D1EABA for ; Thu, 29 Apr 2004 18:40:34 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 86666-09 for ; Thu, 29 Apr 2004 18:40:15 -0300 (ADT) Received: from mail.deg.cc (mail.deg.cc [198.70.16.196]) by svr1.postgresql.org (Postfix) with ESMTP id D4022D1EA9C for ; Thu, 29 Apr 2004 18:40:12 -0300 (ADT) Received: from deg.cc (barney.deg.cc [198.70.16.205]) by mail.deg.cc (Postfix) with ESMTP id 247EC55F84; Thu, 29 Apr 2004 17:40:09 -0400 (EDT) Message-ID: <40917768.8040107@deg.cc> Date: Thu, 29 Apr 2004 17:45:12 -0400 From: Pallav Kalva User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4.2) Gecko/20040308 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "scott.marlowe" Cc: pgsql-sql@postgresql.org Subject: Re: Permissions not working References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200404/326 X-Sequence-Number: 17701 scott.marlowe wrote: >On Thu, 29 Apr 2004, Pallav Kalva wrote: > > > >>Hi , >> >> I am having some problems with setting up permissions in Postgres. I >>have a database for ex: 'ups' and it was owned previously by >>'postgres(superuser)' but now i have changed the ownership to new user >>'ups' all the tables are owned by these user 'ups'. This database doesnt >>have any schemas except for 'Public'. I have created another user lets >>say 'test' and i didnt give 'test' user any permissions to access the >>tables owned by 'ups' but still when i login to 'ups' database as psql >>ups test and run a select on the tables owned by 'ups' database it >>goes through. >> I dont want user 'test' to access any tables from the 'ups' >>database, i tried revoking permissions it still doesnt work. Can anyone >>tell me what is wrong here ? >> >> > >Log in as the superuser (usually postgres) and see what you get from this >query: > >select usesuper from pg_shadow where usename='test'; > >if usesuper is t, then test is a superuser and can do anything he wants. >You need to issue the command: > >alter user test with nocreateuser; > >If that isn't the problem, let us know. > > Thanks! for the quick reply, I ran the above query and it is 'f' for the 'test' user, 'test' is not a super user.