Re: [GENERAL] No PUBLIC access by default?

2005-08-12 Thread Peter Fein
Tom Lane wrote: Peter Fein [EMAIL PROTECTED] writes: If I read my ACL's correctly, =UC/postgres means full access for PUBLIC. Why is that happening? Because that's the way it's set up in template1. CREATE DATABASE just copies the source database, it doesn't editorialize on the contents

Re: [GENERAL] No PUBLIC access by default?

2005-08-12 Thread Tom Lane
Peter Fein [EMAIL PROTECTED] writes: In particular, by writing TEMPLATE template0, you can create a virgin database containing only the standard objects predefined by your version of PostgreSQL. I guess I'm just surprised that template0 would have *any* ACLs set PUBLIC is one of the standard

Re: [GENERAL] No PUBLIC access by default?

2005-08-12 Thread Martijn van Oosterhout
On Fri, Aug 12, 2005 at 08:34:23AM -0500, Peter Fein wrote: Ok. ;) A little further investigation revealed that template0 gives the same result. It's potentially confusing that template0 is initialized this way - I couldn't find any indication of such in the manual. In fact, from CREATE

Re: [GENERAL] No PUBLIC access by default?

2005-08-12 Thread Peter Fein
Martijn van Oosterhout wrote: On Fri, Aug 12, 2005 at 08:34:23AM -0500, Peter Fein wrote: Ok. ;) A little further investigation revealed that template0 gives the same result. It's potentially confusing that template0 is initialized this way - I couldn't find any indication of such in the

[GENERAL] No PUBLIC access by default?

2005-08-11 Thread Peter Fein
Hi all- Is there any way to disable PUBLIC access by default? When I create a new object (table, function, etc.), it has no ACL, as expected. However, the first time I run: GRANT ALL ON FUNCTION foo() to GROUP developers; Postgress seems to do: GRANT ALL ON FUNCTION foo() to PUBLIC; I assume

Re: [GENERAL] No PUBLIC access by default?

2005-08-11 Thread Alvaro Herrera
On Thu, Aug 11, 2005 at 12:28:44PM -0500, Peter Fein wrote: Is there any way to disable PUBLIC access by default? When I create a new object (table, function, etc.), it has no ACL, as expected. However, the first time I run: GRANT ALL ON FUNCTION foo() to GROUP developers; Postgress

Re: [GENERAL] No PUBLIC access by default?

2005-08-11 Thread Tom Lane
Alvaro Herrera [EMAIL PROTECTED] writes: Actually, that last grant is implicit. When an ACL is found to be null, it's considered to have a grant to public. No, it's considered to be whatever the default for the object type is. Read the GRANT manual page. regards, tom

Re: [GENERAL] No PUBLIC access by default?

2005-08-11 Thread Guy Rouillier
Peter Fein wrote: Hi all- Is there any way to disable PUBLIC access by default? When I create You can revoke permissions from the public schema, and you can even delete the public schema entirely. I did the first: revoke create on schema public from public revoke create on tablespace

Re: [GENERAL] No PUBLIC access by default?

2005-08-11 Thread Peter Fein
Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: Actually, that last grant is implicit. When an ACL is found to be null, it's considered to have a grant to public. No, it's considered to be whatever the default for the object type is. Read the GRANT manual page. I'm obviously

Re: [GENERAL] No PUBLIC access by default?

2005-08-11 Thread Tom Lane
Peter Fein [EMAIL PROTECTED] writes: If I read my ACL's correctly, =UC/postgres means full access for PUBLIC. Why is that happening? Because that's the way it's set up in template1. CREATE DATABASE just copies the source database, it doesn't editorialize on the contents thereof.