Re: Non-superuser subscription owners - Mailing list pgsql-hackers

From Jeff Davis
Subject Re: Non-superuser subscription owners
Date
Msg-id 455caca96481c4a0c9d56fd6be8eda970cdc7267.camel@j-davis.com
Whole thread Raw
In response to Re: Non-superuser subscription owners  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Non-superuser subscription owners  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On Thu, 2023-03-23 at 11:52 -0400, Robert Haas wrote:
> What would this amount to concretely? Also adding a
> pg_connection_string predefined role and requiring both that and
> pg_create_subscription [to CREATE SUBSCRIPTION]

Yes.

> If so, I don't think that's a good idea. Maybe for some reason your
> proposed changes won't end up happening, and then we've just got a
> useless extra thing that makes things confusing.

Even if my changes don't happen, I would find it less confusing and
more likely that users understand what they're doing.

To most users, the consequences of allowing users to write connection
strings on the server are far from obvious. Even we, as developers,
needed to spend a lot of time discussing the nuances.

Someone merely granting the ability to CREATE SUBSCRIPTION would read
that page in the docs, which is dominated by the mechanics of a
subscription and says little about the connection string, let alone the
security nuances of using it on a server.

But if there is also a separate connection string privilege required,
we can document it better and they are more likely to find it and
understand.

Beyond that, the connection string and the mechanics of the
subscription are really different concepts.

Regards,
    Jeff Davis




pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: HOT chain validation in verify_heapam()
Next
From: Peter Geoghegan
Date:
Subject: Re: Add n_tup_newpage_upd to pg_stat table views