pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
7+ messages / 1 participants
[nested] [flat]

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/95cce56696867c7629d12c3ba1da8edd5bedaa8e

Modified Files
--------------
src/backend/commands/statscmds.c        | 16 +++++++++++++++-
src/backend/commands/tablecmds.c        |  2 +-
src/backend/tcop/utility.c              |  2 +-
src/include/commands/defrem.h           |  2 +-
src/test/regress/expected/stats_ext.out | 19 +++++++++++++++++++
src/test/regress/sql/stats_ext.sql      | 19 +++++++++++++++++++
6 files changed, 56 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
REL_18_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/00eb646ea43410e5df77fed96f4a981e66811796

Modified Files
--------------
src/backend/commands/statscmds.c        | 17 ++++++++++++++-
src/backend/commands/tablecmds.c        |  2 +-
src/backend/tcop/utility.c              |  2 +-
src/include/commands/defrem.h           |  2 +-
src/test/regress/expected/stats_ext.out | 37 +++++++++++++++++++++++++++++++++
src/test/regress/sql/stats_ext.sql      | 34 ++++++++++++++++++++++++++++++
6 files changed, 90 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
REL_13_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/8a2530ebcdef1aafa08ad1d019aec298dcebb952

Modified Files
--------------
src/backend/commands/statscmds.c        |  8 ++++++++
src/test/regress/expected/stats_ext.out | 14 ++++++++++++++
src/test/regress/sql/stats_ext.sql      | 13 +++++++++++++
3 files changed, 35 insertions(+)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
REL_15_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/2393d374ae9c0bc8327adc80fe4490edb05be167

Modified Files
--------------
src/backend/commands/statscmds.c        | 16 +++++++++++++++-
src/backend/commands/tablecmds.c        |  2 +-
src/backend/tcop/utility.c              |  2 +-
src/include/commands/defrem.h           |  2 +-
src/test/regress/expected/stats_ext.out | 19 +++++++++++++++++++
src/test/regress/sql/stats_ext.sql      | 19 +++++++++++++++++++
6 files changed, 56 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/5e4fcbe531c668b4112beedde97aac79724074c5

Modified Files
--------------
src/backend/commands/statscmds.c        | 17 ++++++++++++++-
src/backend/commands/tablecmds.c        |  2 +-
src/backend/tcop/utility.c              |  2 +-
src/include/commands/defrem.h           |  2 +-
src/test/regress/expected/stats_ext.out | 37 +++++++++++++++++++++++++++++++++
src/test/regress/sql/stats_ext.sql      | 34 ++++++++++++++++++++++++++++++
6 files changed, 90 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
REL_17_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/e2fb3dfa817fbe89494a62c100e9cb442f4d6b15

Modified Files
--------------
src/backend/commands/statscmds.c        | 17 ++++++++++++++-
src/backend/commands/tablecmds.c        |  2 +-
src/backend/tcop/utility.c              |  2 +-
src/include/commands/defrem.h           |  2 +-
src/test/regress/expected/stats_ext.out | 37 +++++++++++++++++++++++++++++++++
src/test/regress/sql/stats_ext.sql      | 34 ++++++++++++++++++++++++++++++
6 files changed, 90 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS.
@ 2025-11-10 15:01  Nathan Bossart <nathan@postgresql.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Nathan Bossart @ 2025-11-10 15:01 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Check for CREATE privilege on the schema in CREATE STATISTICS.

This omission allowed table owners to create statistics in any
schema, potentially leading to unexpected naming conflicts.  For
ALTER TABLE commands that require re-creating statistics objects,
skip this check in case the user has since lost CREATE on the
schema.  The addition of a second parameter to CreateStatistics()
breaks ABI compatibility, but we are unaware of any impacted
third-party code.

Reported-by: Jelte Fennema-Nio <postgres@jeltef.nl>
Author: Jelte Fennema-Nio <postgres@jeltef.nl>
Co-authored-by: Nathan Bossart <nathandbossart@gmail.com>
Reviewed-by: Noah Misch <noah@leadboat.com>
Reviewed-by: Álvaro Herrera <alvherre@kurilemu.de>
Security: CVE-2025-12817
Backpatch-through: 13

Branch
------
REL_16_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/d20abb5876ab61a627d80131b2cb78d9652557e3

Modified Files
--------------
src/backend/commands/statscmds.c        | 17 +++++++++++++++-
src/backend/commands/tablecmds.c        |  2 +-
src/backend/tcop/utility.c              |  2 +-
src/include/commands/defrem.h           |  2 +-
src/test/regress/expected/stats_ext.out | 36 +++++++++++++++++++++++++++++++++
src/test/regress/sql/stats_ext.sql      | 33 ++++++++++++++++++++++++++++++
6 files changed, 88 insertions(+), 4 deletions(-)



^ permalink  raw  reply  [nested|flat] 7+ messages in thread


end of thread, other threads:[~2025-11-10 15:01 UTC | newest]

Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>
2025-11-10 15:01 pgsql: Check for CREATE privilege on the schema in CREATE STATISTICS. Nathan Bossart <nathan@postgresql.org>

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