postgresql/src
Tom Lane 650d950efc Prevent PL/Tcl from loading the "unknown" module from pltcl_modules unless
that is a regular table or view owned by a superuser.  This prevents a
trojan horse attack whereby any unprivileged SQL user could create such a
table and insert code into it that would then get executed in other users'
sessions whenever they call pltcl functions.

Worse yet, because the code was automatically loaded into both the "normal"
and "safe" interpreters at first use, the attacker could execute unrestricted
Tcl code in the "normal" interpreter without there being any pltclu functions
anywhere, or indeed anyone else using pltcl at all: installing pltcl is
sufficient to open the hole.  Change the initialization logic so that the
"unknown" code is only loaded into an interpreter when the interpreter is
first really used.  (That doesn't add any additional security in this
particular context, but it seems a prudent change, and anyway the former
behavior violated the principle of least astonishment.)

Security: CVE-2010-1170
2010-05-13 18:29:31 +00:00
..
backend Translation update 2010-05-13 07:32:39 +00:00
bin Fix psql to not go into infinite recursion when expanding a variable that 2010-05-05 22:19:18 +00:00
include Don't pass an invalid file handle to dup2(). That causes a crash on 2010-04-01 20:12:43 +00:00
interfaces Translation update 2010-05-13 07:32:39 +00:00
makefiles Add $(CFLAGS) to the simplified build rule for .so libraries on Darwin. 2006-11-28 05:45:43 +00:00
pl Prevent PL/Tcl from loading the "unknown" module from pltcl_modules unless 2010-05-13 18:29:31 +00:00
port tag 8.2.16 2010-03-12 03:44:14 +00:00
template Make --with-ldap build on Unixware, per Olivier Prenant. 2006-12-14 21:50:07 +00:00
test Fix the handling of sub-SELECTs appearing in the arguments of an outer-level 2009-04-25 16:45:12 +00:00
timezone Update time zone data files to tzdata release 2010j: DST law changes in 2010-05-11 23:01:49 +00:00
tools Backpatch MSVC build fix for XSLT 2010-03-02 15:43:11 +00:00
tutorial Fix some misuses of strncat(). 2006-09-27 16:19:42 +00:00
bcc32.mak Fix bcc32.mak to create and remove pg_config_os.h properly. Apparently 2006-10-06 18:53:53 +00:00
DEVELOPERS Testing commit stuff 2006-07-10 15:50:02 +00:00
Makefile Remove dllinit.c; it was only needed for long-obsolete Cygwin versions, 2006-06-22 23:50:35 +00:00
Makefile.global.in On Windows, we know the backend stack size limit because we have to 2006-10-08 17:15:34 +00:00
Makefile.shlib Fix shared library creation to work properly on AIX. Albe Laurenz 2006-09-19 15:36:08 +00:00
nls-global.mk When merging PO files, take into consideration translations in other PO 2006-04-05 13:40:15 +00:00
win32.mak Fix win32.mak for config cleanup. 2006-08-08 22:44:05 +00:00