git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: 448fee2) | patch
Switch user ID to the object owner when populating a materialized view.
2013年7月12日 22:21:22 +0000 (18:21 -0400)
2013年7月12日 22:21:22 +0000 (18:21 -0400)
commit f3ab5d46960023cf8a9df3751ab9748ce01a46a0
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.
doc/src/sgml/ref/create_materialized_view.sgml diff | blob | blame | history
src/backend/commands/createas.c diff | blob | blame | history
src/backend/commands/matview.c diff | blob | blame | history
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /