postgresql/src
Noah Misch fb7c0ac42e Switch user ID to the object owner when populating a materialized view.
This makes superuser-issued REFRESH MATERIALIZED VIEW safe regardless of
the object's provenance.  REINDEX is an earlier example of this pattern.
As a downside, functions called from materialized views must tolerate
running in a security-restricted operation.  CREATE MATERIALIZED VIEW
need not change user ID.  Nonetheless, avoid creation of materialized
views that will invariably fail REFRESH by making it, too, start a
security-restricted operation.

Back-patch to 9.3 so materialized views have this from the beginning.

Reviewed by Kevin Grittner.
2013-07-12 18:25:41 -04:00
..
backend Switch user ID to the object owner when populating a materialized view. 2013-07-12 18:25:41 -04:00
bin pg_dump: Formatting cleanup of new messages 2013-07-11 21:48:31 -04:00
common pgindent run for release 9.3 2013-05-29 16:58:43 -04:00
include Fix include-guard 2013-07-07 13:38:27 +02:00
interfaces Also escape double quotes for ECPG's #line statement. 2013-07-06 22:11:14 +02:00
makefiles Blind attempt at fixing the non-MSVC Windows builds 2013-02-22 11:51:15 -03:00
pl Update messages, comments and documentation for materialized views. 2013-07-05 15:26:46 -04:00
port Use SA_RESTART for all signals, including SIGALRM. 2013-06-15 15:40:05 -04:00
template Remove _FORTIFY_SOURCE 2012-10-10 21:42:38 -04:00
test Fix planning of parameterized appendrel paths with expensive join quals. 2013-07-07 22:37:28 -04:00
timezone pgindent run for release 9.3 2013-05-29 16:58:43 -04:00
tools Minor spelling fixes 2013-06-01 10:18:59 -04:00
tutorial Modernize string literal syntax in tutorial example. 2013-01-19 17:20:32 -05:00
.gitignore Convert cvsignore to gitignore, and add .gitignore for build targets. 2010-09-22 12:57:04 +02:00
bcc32.mak Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00
DEVELOPERS
Makefile Create libpgcommon, and move pg_malloc et al to it 2013-02-12 11:21:05 -03:00
Makefile.global.in Remove whitespace from end of lines 2013-05-30 21:05:07 -04:00
Makefile.shlib Add pkg-config files for libpq and ecpg libraries 2013-03-31 16:58:40 -04:00
nls-global.mk NLS: Use msgmerge --previous option 2012-12-13 23:12:12 -05:00
win32.mak Autoconfiscate selection of 64-bit int type for 64-bit large object API. 2012-10-07 21:52:43 -04:00