pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
BUG #17106: Renaming system types is possible and it potentially leads to a crash
3+ messages / 3 participants
[nested] [flat]

* BUG #17106: Renaming system types is possible and it potentially leads to a crash
@ 2021-07-15 04:00  PG Bug reporting form <noreply@postgresql.org>
  0 siblings, 2 replies; 3+ messages in thread

From: PG Bug reporting form @ 2021-07-15 04:00 UTC (permalink / raw)
  To: pgsql-bugs@lists.postgresql.org; +Cc: exclusion@gmail.com

The following bug has been logged on the website:

Bug reference:      17106
Logged by:          Alexander Lakhin
Email address:      exclusion@gmail.com
PostgreSQL version: 13.3
Operating system:   Ubuntu 20.04
Description:        

While dropping system types is prohibited (say, you can't DROP TYPE void),
renaming is not. So the following commands lead to an inevitable crash.
ALTER TYPE void RENAME TO void_void;
CREATE TABLE void(id int);
CREATE EXTENSION pg_stat_statements;
SELECT pg_stat_statements_reset();

(Superuser rights required for this, though.)



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

* Re: BUG #17106: Renaming system types is possible and it potentially leads to a crash
@ 2021-07-15 07:42  Michael Paquier <michael@paquier.xyz>
  parent: PG Bug reporting form <noreply@postgresql.org>
  1 sibling, 0 replies; 3+ messages in thread

From: Michael Paquier @ 2021-07-15 07:42 UTC (permalink / raw)
  To: exclusion@gmail.com; pgsql-bugs@lists.postgresql.org

On Thu, Jul 15, 2021 at 04:00:01AM +0000, PG Bug reporting form wrote:
> While dropping system types is prohibited (say, you can't DROP TYPE void),
> renaming is not. So the following commands lead to an inevitable crash.
> ALTER TYPE void RENAME TO void_void;
> CREATE TABLE void(id int);
> CREATE EXTENSION pg_stat_statements;
> SELECT pg_stat_statements_reset();
> 
> (Superuser rights required for this, though.)

Like one of those many stupid things one can do as a superuser :)

This does not seem worth worrying about to me.
--
Michael

Attachments:

  signature.asc (application/pgp-signature, 832B) download

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

* Re: BUG #17106: Renaming system types is possible and it potentially leads to a crash
@ 2021-07-15 15:26  Francisco Olarte <folarte@peoplecall.com>
  parent: PG Bug reporting form <noreply@postgresql.org>
  1 sibling, 0 replies; 3+ messages in thread

From: Francisco Olarte @ 2021-07-15 15:26 UTC (permalink / raw)
  To: exclusion@gmail.com, PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>

On Thu, Jul 15, 2021 at 9:21 AM PG Bug reporting form
<noreply@postgresql.org> wrote:
...
> While dropping system types is prohibited (say, you can't DROP TYPE void),
> renaming is not. So the following commands lead to an inevitable crash.
... example removed.
> (Superuser rights required for this, though.)

Any competent programmer can crash a machine, any competent DBA can
crash a DB, anyone with physical access can unplug a server, or set it
on fire.

Given it is not an easy mistake to make ( "DROP type void" is way more
dangerous, being so simple ), I would consider this anecdotal. I doubt
"survive an hostile DBA" is an objective for postgresql.

Francisco Olarte.





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


end of thread, other threads:[~2021-07-15 15:26 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-07-15 04:00 BUG #17106: Renaming system types is possible and it potentially leads to a crash PG Bug reporting form <noreply@postgresql.org>
2021-07-15 07:42 ` Michael Paquier <michael@paquier.xyz>
2021-07-15 15:26 ` Francisco Olarte <folarte@peoplecall.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