aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/user.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2020-11-03 15:49:05 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2020-11-03 15:49:05 -0500
commit17fb60387ce3fdc2bbb13d9b67bed0e4da77e173 (patch)
treecf14248c866b6f2c7a8588bbbc89491ea280a6f0 /src/backend/commands/user.c
parentd907bd0543aa63e59653d7345840bed0f8b3a83b (diff)
downloadpostgresql-17fb60387ce3fdc2bbb13d9b67bed0e4da77e173.tar.gz
postgresql-17fb60387ce3fdc2bbb13d9b67bed0e4da77e173.zip
Improve error messages around REPLICATION and BYPASSRLS properties.
Clarify wording as per suggestion from Wolfgang Walther. No back-patch; this doesn't seem worth thrashing translatable strings in the back branches. Tom Lane and Stephen Frost Discussion: https://postgr.es/m/a5548a9f-89ee-3167-129d-162b5985fcf8@technowledgy.de
Diffstat (limited to 'src/backend/commands/user.c')
-rw-r--r--src/backend/commands/user.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/commands/user.c b/src/backend/commands/user.c
index 293e7e4c0c1..0e6800bf3e4 100644
--- a/src/backend/commands/user.c
+++ b/src/backend/commands/user.c
@@ -305,7 +305,7 @@ CreateRole(ParseState *pstate, CreateRoleStmt *stmt)
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- errmsg("must be superuser to change bypassrls attribute")));
+ errmsg("must be superuser to create bypassrls users")));
}
else
{
@@ -719,14 +719,14 @@ AlterRole(AlterRoleStmt *stmt)
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- errmsg("must be superuser to alter superusers")));
+ errmsg("must be superuser to alter superuser roles or change superuser attribute")));
}
else if (authform->rolreplication || isreplication >= 0)
{
if (!superuser())
ereport(ERROR,
(errcode(ERRCODE_INSUFFICIENT_PRIVILEGE),
- errmsg("must be superuser to alter replication users")));
+ errmsg("must be superuser to alter replication roles or change replication attribute")));
}
else if (bypassrls >= 0)
{