pg.ddx.io pgsql-bugs@postgresql.org mailing list archive
help / color / mirror / Atom feedBUG #16464: Unable to restore database backed up with pg_dump into sql that contains expression based index
2+ messages / 2 participants
[nested] [flat]
* BUG #16464: Unable to restore database backed up with pg_dump into sql that contains expression based index
@ 2020-05-26 17:00 PG Bug reporting form <noreply@postgresql.org>
2020-05-26 17:53 ` Re: BUG #16464: Unable to restore database backed up with pg_dump into sql that contains expression based index David G. Johnston <david.g.johnston@gmail.com>
0 siblings, 1 reply; 2+ messages in thread
From: PG Bug reporting form @ 2020-05-26 17:00 UTC (permalink / raw)
To: pgsql-bugs@lists.postgresql.org; +Cc: pguser17354@mailinator.com
The following bug has been logged on the website:
Bug reference: 16464
Logged by: pg user
Email address: pguser17354@mailinator.com
PostgreSQL version: 12.3
Operating system: Centos 6
Description:
Hello,
Restoring from pg_dump fails if you have a table with expression based index
where a stored function calls another function.
Ex. SQL with steps to reproduce: https://pastebin.com/raw/CFgxtwSY
Related to:
https://wiki.postgresql.org/wiki/A_Guide_to_CVE-2018-1058:_Protect_Your_Search_Path
Workaround:
Removing "SELECT pg_catalog.set_config('search_path', '', false);" from the
sql dump.
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: BUG #16464: Unable to restore database backed up with pg_dump into sql that contains expression based index
2020-05-26 17:00 BUG #16464: Unable to restore database backed up with pg_dump into sql that contains expression based index PG Bug reporting form <noreply@postgresql.org>
@ 2020-05-26 17:53 ` David G. Johnston <david.g.johnston@gmail.com>
0 siblings, 0 replies; 2+ messages in thread
From: David G. Johnston @ 2020-05-26 17:53 UTC (permalink / raw)
To: pguser17354@mailinator.com, PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>
On Tue, May 26, 2020 at 10:23 AM PG Bug reporting form <
noreply@postgresql.org> wrote:
> The following bug has been logged on the website:
>
> Bug reference: 16464
> Logged by: pg user
> Email address: pguser17354@mailinator.com
> PostgreSQL version: 12.3
> Operating system: Centos 6
> Description:
>
> Hello,
> Restoring from pg_dump fails if you have a table with expression based
> index
> where a stored function calls another function.
> Ex. SQL with steps to reproduce: https://pastebin.com/raw/CFgxtwSY
>
> Related to:
>
> https://wiki.postgresql.org/wiki/A_Guide_to_CVE-2018-1058:_Protect_Your_Search_Path
>
> Workaround:
> Removing "SELECT pg_catalog.set_config('search_path', '', false);" from the
> sql dump.
>
This isn't a bug. Your workaround is perfectly acceptable for an end-user
to attempt should they wish but it isn't something the project is going to
entertain - though I seem to recall a discussion of at least giving the
user control by adding a command line argument (as I mentioned before at
[1] but still cannot find the original thread).
An obvious failure to restore a backup is not going to win out in a
security risk comparison with being able to silently cause a privileged
user to execute problem code.
[1]
https://www.postgresql.org/message-id/CAKFQuwZ9xGQF%3DQTPUKUNoco9fjmM9WruCaDh5AmDc-RwQop0Cw%40mail.g...
David J.
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2020-05-26 17:53 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2020-05-26 17:00 BUG #16464: Unable to restore database backed up with pg_dump into sql that contains expression based index PG Bug reporting form <noreply@postgresql.org>
2020-05-26 17:53 ` David G. Johnston <david.g.johnston@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox