Unix Technical Forum

Authorized privileges when calling a procedure

This is a discussion on Authorized privileges when calling a procedure within the pgsql Novice forums, part of the PostgreSQL category; --> Hi, I have another question. It appears that when you create a procedure and grant access on it to ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Novice

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-17-2008, 08:44 PM
Walker, Jed S
 
Posts: n/a
Default Authorized privileges when calling a procedure

Hi,

I have another question. It appears that when you create a procedure and
grant access on it to another user, the user must have privileges to all
objects that the procedure references. Can someone confirm this, and is
there a way to change the privilege authorization to the user that defined
the procedure?

> Thanks in advance,
>
> Jed S. Walker
>
>
>


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-17-2008, 08:44 PM
Tom Lane
 
Posts: n/a
Default Re: Authorized privileges when calling a procedure

"Walker, Jed S" <Jed_Walker@cable.comcast.com> writes:
> I have another question. It appears that when you create a procedure and
> grant access on it to another user, the user must have privileges to all
> objects that the procedure references. Can someone confirm this, and is
> there a way to change the privilege authorization to the user that defined
> the procedure?


Mark the function as SECURITY DEFINER --- this is like setuid programs
in Unix.

(No, it's not a very intuitive label for the behavior, but it's what
the SQL spec says to use.)

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
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
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 04:15 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com