Conversation
Functions referencing objects without schema are susceptible to accessing unintented objects depending on the search_path they are executed with. This patch adds a search_path to all the SQL and PLPGSQL functions to ensure the intended objects are accessed.
|
@svenklemm thank you for the contribution! Currently Line 550 in 306b0d4 Does the PR improve handling of issue of calling unintented objects? BTW there are still views |
|
During view creation object references are pinned to the objects according to the search path during creation. But this does not apply to indirect references, e.g. unspecified object references in functions called in a view. With explicit search_path like that things used by pg_repack binary are safe. This is hardening for callers outside of the binary using the views provided by pg_repack. |
Functions referencing objects without schema are susceptible to accessing unintented objects depending on the search_path they are executed with. This patch adds a search_path to all the SQL and PLPGSQL functions to ensure the intended objects are accessed.