From: | Zeugswetter Andreas <andreas(dot)zeugswetter(at)telecom(dot)at> |
---|---|
To: | "'Thomas G(dot) Lockhart'" <lockhart(at)alumni(dot)caltech(dot)edu> |
Cc: | "'pgsql-hackers(at)hub(dot)org'" <pgsql-hackers(at)hub(dot)org> |
Subject: | AW: [HACKERS] Re: PostgreSQL reference manual |
Date: | 1998-03-25 10:08:42 |
Message-ID: | 01BD57DE.61FD7A40@pc9358.sd.spardat.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
>> > > I have another question about GRANT/REVOKE:
>> > >
>> > > grant <privilege[,privilege,...]>
>> > > on <rel1>[,...<reln>]
>> > > to [public | GROUP <group> | <username>]
>> > > ^^^^^^^^^^^^^
>> > > I don't know how to create a GROUP ?
>> >
>> > I believe that you use "CREATE USER groupname", and then can assign
>> > privileges to that pseudo-user/group, and then add users to that
>> > group. Have you tried that?
>> postgres=> create user grupo;
>> CREATE USER
No, do this: insert into pg_group values ('grupo', 100, '{6}');
>> postgres=> grant all on tmp to grupo;
>> CHANGE
>> create user joe in group grupo;
looks like this is ignored ?
>> CREATE USER
>> postgres=> grant select on tmp to group grupo;
>> ERROR: non-existent group "grupo"
>
>Can someone tell us how "groups" work? I'm not finding enough clues just
>by looking in the parser, and haven't stumbled across it in the docs...
I have no idea what the grosysid is supposed to be, I only notice, that 100 works while 18204
crashes psql. To be consistent with pg_user I think it should hold the unix group id,
if the group also exists in /etc/groups. If not, from what I see in the sources
it must still be unique, see src/backend/catalog/aclchk.c ** this code is a little mess really **
The field grolist has to be manually maintained currently. It contains an
array of usesysid's of the users in this group. (select usesysid from pg_user where usename='joe';)
Andreas
From | Date | Subject | |
---|---|---|---|
Next Message | Blu3Viper | 1998-03-25 10:28:41 | Re: [QUESTIONS] my postgresql moves to a Digital server, but... |
Previous Message | SC Altex Impex SRL | 1998-03-25 09:45:57 | my postgresql moves to a Digital server, but... |