Re: [HACKERS] What about CREATE OR REPLACE FUNCTION?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Jean-Michel POURE <jm(dot)poure(at)freesurf(dot)fr>, pgsql-hackers(at)postgresql(dot)org, Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, pgadmin-hackers(at)postgresql(dot)org
Subject: Re: [HACKERS] What about CREATE OR REPLACE FUNCTION?
Date: 2001-10-09 17:27:41
Message-ID: 4022.1002648461@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Jean-Michel POURE writes:
>> It is sometimes tricky for Windows users to install a language remotely on
>> a Linux box (no access to createlang and/or no knowledge of handlers).

> Why not run createlang on the host that the server runs on?

I wasn't able to get excited about that argument either.

I believe the primary reason why PL languages aren't installed by
default is security considerations: users can easily create denial-of-
service conditions if given access to a PL. (Example: write infinitely
recursive function, invoke it to cause stack overflow crash in your
backend, which forces database-wide restart, thereby negating other
people's transactions. Repeat until DBA kicks you off...)

A DBA who does want to give access to PL languages by default can
easily do so by installing them into template1, whence they'll be
automatically duplicated into newly created databases. Perhaps this
option needs to be documented more prominently.

regards, tom lane

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2001-10-09 22:36:24 Re: [HACKERS] What about CREATE OR REPLACE FUNCTION?
Previous Message Peter Eisentraut 2001-10-09 17:13:01 Re: [HACKERS] What about CREATE OR REPLACE FUNCTION?

Browse pgsql-hackers by date

  From Date Subject
Next Message Oleg Bartunov 2001-10-09 18:06:45 Re: Problem with cyrilic
Previous Message Peter Eisentraut 2001-10-09 17:13:01 Re: [HACKERS] What about CREATE OR REPLACE FUNCTION?