dbTalk Databases Forums  

Permissions on trigger function

comp.databases.postgresql comp.databases.postgresql


Discuss Permissions on trigger function in the comp.databases.postgresql forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Boris
 
Posts: n/a

Default Permissions on trigger function - 12-15-2010 , 07:44 AM






Hello,

I have postgres 8.3 server. Trying to deny a user ability to execute
postgres function. Everything works fine with a regular function. I
created a function as security invoked, then I can revoke all on my
function from public; then, when trying to execute it as this user, I
get "permission denied" as expected. Good.
Things are not as clear to me if this function is a trigger
function and is called by a trigger on table insert. Ideally I want
the insert to be denied, but looks like the function is not executed
in security context of the invoker OR permissions are not checked at
all. User can successfully insert into the table even when all
permissions on the tigger function are revoked.

Thanks.

Reply With Quote
  #2  
Old   
Jasen Betts
 
Posts: n/a

Default Re: Permissions on trigger function - 12-16-2010 , 02:13 PM






On 2010-12-15, Boris <boris.partensky (AT) gmail (DOT) com> wrote:
Quote:
Hello,

User can successfully insert into the table even when all
permissions on the tigger function are revoked.
revoke the users insert permission for the table

--
⚂⚃ 100% natural

Reply With Quote
  #3  
Old   
Boris
 
Posts: n/a

Default Re: Permissions on trigger function - 12-17-2010 , 07:01 AM



Hi Jasen, thanks for the reply.

Quote:
revoke the users insert permission for the table
Yes, but my question was more about trigger function permissions
rather than
how to not allow user insert into table. Are you saying that what I am
describing is a known, intended behavior?
Why are permissions on function ignored?

On Dec 16, 3:13Â*pm, Jasen Betts <ja... (AT) xnet (DOT) co.nz> wrote:
Quote:
On 2010-12-15, Boris <boris.parten... (AT) gmail (DOT) com> wrote:

Hello,
User can successfully insert into the table even when all
permissions on the tigger function are revoked.

revoke the users insert permission for the table

--
⚂⚃ 100% natural

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.