BUG #18281: Superuser can rename the schema with the prefix "pg_" (Applies to all versions of postgresql)

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: szyjek9302(at)gmail(dot)com
Subject: BUG #18281: Superuser can rename the schema with the prefix "pg_" (Applies to all versions of postgresql)
Date: 2024-01-10 13:41:58
Message-ID: 18281-5b1b6c5991d345aa@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 18281
Logged by: Maciej Szeliga
Email address: szyjek9302(at)gmail(dot)com
PostgreSQL version: 16.1
Operating system: centos 8
Description:

Hi,
I renamed the schema pg_toast
moja=# alter schema pg_toast rename to x_pg_toast
moja-# ;
ALTER SCHEMA

and can't undo it because :

moja=# alter schema x_pg_toast rename to pg_toast;
ERROR: unacceptable schema name "pg_toast"
DETAIL: The prefix "pg_" is reserved for system schemas.

I think this is a serious problem that should be fixed by developers. The
superuser should not be able to rename system schemas.

Regards
Maciej

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message feichanghong 2024-01-10 13:56:00 Re:BUG #18280: logical decoding build wrong snapshot for subtransactions
Previous Message PG Bug reporting form 2024-01-10 12:51:08 BUG #18280: logical decoding build wrong snapshot for subtransactions