agora inbox for pgsql-committers@postgresql.org  
help / color / mirror / Atom feed
pgsql: Revert "Support more object types within CREATE SCHEMA".
2+ messages / 1 participants
[nested] [flat]

* pgsql: Revert "Support more object types within CREATE SCHEMA".
@ 2026-09-11 15:38 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 2+ messages in thread

From: Tom Lane @ 2026-09-11 15:38 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Revert "Support more object types within CREATE SCHEMA".

This reverts commit d516974840f4059d331ae6057ede3e4edd3c6747,
along with parts of commit 049b742daad0965be4a846035408ae27ce1f9e14
("psql: Tighten heuristics for BEGIN/END within CREATE SCHEMA").

While there's nothing particularly wrong with d51697484 in itself,
it depends on a9c350d9e ("Don't try to re-order the subcommands of
CREATE SCHEMA"), and concerns have been raised that the compatibility
impact of that outweighs the benefit of allowing more object types
within CREATE SCHEMA.

It's not possible to revert 049b742da verbatim, because the
CVE-2026-6464 patches 3045a25ba ("Teach psql to skip in-line COPY
... FROM STDIN data after a failure") and cf754f741 ("Save/restore
more lexer state when skipping text due to \if") depend on
infrastructure it added.  Instead, rip out just the bits specifically
needed to parse CREATE FUNCTION within CREATE SCHEMA.  This results in
lexer code that matches v18-and-earlier as modified by CVE-2026-6464.

Author: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://postgr.es/m/20260904180712.cc.noahmisch@microsoft.com
Backpatch-through: 19

Branch
------
master

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

Modified Files
--------------
doc/src/sgml/ref/create_schema.sgml                |  25 +---
src/backend/parser/gram.y                          |   3 -
src/backend/parser/parse_utilcmd.c                 |  88 ------------
src/bin/psql/psqlscanslash.l                       |   8 --
src/bin/psql/tab-complete.in.c                     |  22 ++-
src/fe_utils/psqlscan.l                            |  61 ++-------
src/include/fe_utils/psqlscan_int.h                |   6 -
.../test_ddl_deparse/expected/create_schema.out    |  38 +-----
.../modules/test_ddl_deparse/sql/create_schema.sql |  18 +--
src/test/regress/expected/create_schema.out        | 147 +--------------------
src/test/regress/sql/create_schema.sql             |  81 +-----------
11 files changed, 31 insertions(+), 466 deletions(-)



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

* pgsql: Revert "Support more object types within CREATE SCHEMA".
@ 2026-09-11 15:38 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 2+ messages in thread

From: Tom Lane @ 2026-09-11 15:38 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Revert "Support more object types within CREATE SCHEMA".

This reverts commit d516974840f4059d331ae6057ede3e4edd3c6747,
along with parts of commit 049b742daad0965be4a846035408ae27ce1f9e14
("psql: Tighten heuristics for BEGIN/END within CREATE SCHEMA").

While there's nothing particularly wrong with d51697484 in itself,
it depends on a9c350d9e ("Don't try to re-order the subcommands of
CREATE SCHEMA"), and concerns have been raised that the compatibility
impact of that outweighs the benefit of allowing more object types
within CREATE SCHEMA.

It's not possible to revert 049b742da verbatim, because the
CVE-2026-6464 patches 3045a25ba ("Teach psql to skip in-line COPY
... FROM STDIN data after a failure") and cf754f741 ("Save/restore
more lexer state when skipping text due to \if") depend on
infrastructure it added.  Instead, rip out just the bits specifically
needed to parse CREATE FUNCTION within CREATE SCHEMA.  This results in
lexer code that matches v18-and-earlier as modified by CVE-2026-6464.

Author: Tom Lane <tgl@sss.pgh.pa.us>
Discussion: https://postgr.es/m/20260904180712.cc.noahmisch@microsoft.com
Backpatch-through: 19

Branch
------
REL_19_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/3c5d28ba64e2b9a309076106cf0b66a013eaf180

Modified Files
--------------
doc/src/sgml/ref/create_schema.sgml                |  25 +---
src/backend/parser/gram.y                          |   3 -
src/backend/parser/parse_utilcmd.c                 |  88 ------------
src/bin/psql/psqlscanslash.l                       |   8 --
src/bin/psql/tab-complete.in.c                     |  22 ++-
src/fe_utils/psqlscan.l                            |  61 ++-------
src/include/fe_utils/psqlscan_int.h                |   6 -
.../test_ddl_deparse/expected/create_schema.out    |  38 +-----
.../modules/test_ddl_deparse/sql/create_schema.sql |  18 +--
src/test/regress/expected/create_schema.out        | 147 +--------------------
src/test/regress/sql/create_schema.sql             |  81 +-----------
11 files changed, 31 insertions(+), 466 deletions(-)



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


end of thread, other threads:[~2026-09-11 15:38 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2026-09-11 15:38 pgsql: Revert "Support more object types within CREATE SCHEMA". Tom Lane <tgl@sss.pgh.pa.us>
2026-09-11 15:38 pgsql: Revert "Support more object types within CREATE SCHEMA". Tom Lane <tgl@sss.pgh.pa.us>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox