pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Guard against null arguments in binary_upgrade_create_empty_exte 2+ messages / 1 participants [nested] [flat]
* pgsql: Guard against null arguments in binary_upgrade_create_empty_exte @ 2016-01-03 21:26 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 2+ messages in thread From: Tom Lane @ 2016-01-03 21:26 UTC (permalink / raw) To: pgsql-committers Guard against null arguments in binary_upgrade_create_empty_extension(). The CHECK_IS_BINARY_UPGRADE macro is not sufficient security protection if we're going to dereference pass-by-reference arguments before it. But in any case we really need to explicitly check PG_ARGISNULL for all the arguments of a non-strict function, not only the ones we expect null values for. Oversight in commits 30982be4e5019684e1772dd9170aaa53f5a8e894 and f92fc4c95ddcc25978354a8248d3df22269201bc. Found by Andreas Seltenreich. (The other usages in pg_upgrade_support.c seem safe.) Branch ------ master Details ------- http://git.postgresql.org/pg/commitdiff/939d10cd8711fdeb7f0ff62c9c6b08e3eddbba3e Modified Files -------------- src/backend/utils/adt/pg_upgrade_support.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 2+ messages in thread
* pgsql: Guard against null arguments in binary_upgrade_create_empty_exte @ 2016-01-03 21:26 Tom Lane <tgl@sss.pgh.pa.us> 0 siblings, 0 replies; 2+ messages in thread From: Tom Lane @ 2016-01-03 21:26 UTC (permalink / raw) To: pgsql-committers Guard against null arguments in binary_upgrade_create_empty_extension(). The CHECK_IS_BINARY_UPGRADE macro is not sufficient security protection if we're going to dereference pass-by-reference arguments before it. But in any case we really need to explicitly check PG_ARGISNULL for all the arguments of a non-strict function, not only the ones we expect null values for. Oversight in commits 30982be4e5019684e1772dd9170aaa53f5a8e894 and f92fc4c95ddcc25978354a8248d3df22269201bc. Found by Andreas Seltenreich. (The other usages in pg_upgrade_support.c seem safe.) Branch ------ REL9_5_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/ab1f08a3a4a855cb9245456866918706ca2fdf06 Modified Files -------------- src/backend/utils/adt/pg_upgrade_support.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2016-01-03 21:26 UTC | newest] Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2016-01-03 21:26 pgsql: Guard against null arguments in binary_upgrade_create_empty_exte Tom Lane <tgl@sss.pgh.pa.us> 2016-01-03 21:26 pgsql: Guard against null arguments in binary_upgrade_create_empty_exte Tom Lane <tgl@sss.pgh.pa.us>
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