Re: [BUG] SECURITY DEFINER on call handler makes daemon crash - Mailing list pgsql-hackers

From Robert Haas
Subject Re: [BUG] SECURITY DEFINER on call handler makes daemon crash
Date
Msg-id 603c8f071003192056qb443f1cxf4e9a07fdfc5cb70@mail.gmail.com
Whole thread Raw
In response to Re: [BUG] SECURITY DEFINER on call handler makes daemon crash  (KaiGai Kohei <kaigai@kaigai.gr.jp>)
List pgsql-hackers
On Fri, Mar 19, 2010 at 10:29 PM, KaiGai Kohei <kaigai@kaigai.gr.jp> wrote:
> Is it an expected behavior that PostgreSQL tries to execute foo() with
> privileges of the owner of language call handler because of its security
> definer property? This server crash is just a result.

I'm inclined to feel (and Tom's response only reinforces this) that
the actual behavior isn't critical.  I'd be happy with (1) executing
foo() with the privileges of the language owner or (2) ignoring the
SECURITY DEFINER attribute in this context and executing foo() without
changing privileges or (3) throwing an error.  We should just do
whatever complicates the code the least.  Your proposed patch seems
good from that point of view, though I'm not clear on whether it's
otherwise reasonable or which of the above behaviors it actually
implements.

...Robert


pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: [BUG] SECURITY DEFINER on call handler makes daemon crash
Next
From: Bruce Momjian
Date:
Subject: 9.0 release notes done