Search code examples
postgresqlamazon-web-servicesamazon-rdsdatabase-permissions

Permission denied to SET SESSION AUTHORIZATION on Amazon Postgres RDS


For my application, I sometimes need to set session authorization to execute certain commands under a given user's permissions.

We're using an RDS behind the application, and our DB superuser on RDS keeps getting permission denied to set session authorization.

Is there a way to enable this on an RDS? Or is it just not a supported operation?

Thanks in advance!


Solution

  • alas, limitations of rds_superuser are not documented

    The rds_superuser role is a pre-defined Amazon RDS role similar to the PostgreSQL superuser role (customarily named postgres in local instances), but with some restrictions. As with the PostgreSQL superuser role, the rds_superuser role has the most privileges on your DB instance

    So if you get permission denied with rds_superuser, you probably just can't do it... (as some more better known limitations, like ownership override, fs related functions, limited extensions list and so on)