Re: Permissions within a function

From: vamsi krishna <vamsi(dot)krishnak(at)gmail(dot)com>
To: Thomas Hallgren <thhal(at)mailblocks(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Permissions within a function
Date: 2004-12-17 19:23:21
Message-ID: 3faf056804121711235407da8d@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Thomas,

Why dont you create a view on the table and access the view rather
than the table. I guess this would resolve the issue.

What ever select statement you want to have on the table you can make
it a select statement of the view. thus restricting the access to the
main table.

Looking forward to hear from you.

Vamsi Krishna Kundeti

On Fri, 17 Dec 2004 20:12:30 +0100, Thomas Hallgren
<thhal(at)mailblocks(dot)com> wrote:
> I'd like some views on the following issue.
>
> The pljava function call handler will resolve a class name using a
> loader that in turn uses a specific table in the PostgreSQL database.
> Hence, the caller of the function must have select permissions on that
> table or the function will fail. I would like to prevent this somehow
> but I don't know how to go about that. Is there any way to bypass the
> permissions when I do an SPI call from within a call handler somehow?
>
> Regards,
> Thomas Hallgren
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> message can get through to the mailing list cleanly
>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Hannu Krosing 2004-12-17 19:40:50 Re: Permissions within a function
Previous Message Thomas Hallgren 2004-12-17 19:12:30 Permissions within a function