]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
doc: Mention REPACK in MAINTAIN privilege descriptions
authorFujii Masao <fujii@postgresql.org>
Thu, 16 Jul 2026 04:37:28 +0000 (13:37 +0900)
committerFujii Masao <fujii@postgresql.org>
Thu, 16 Jul 2026 04:38:13 +0000 (13:38 +0900)
REPACK requires the MAINTAIN privilege, but it was omitted from the
lists of commands covered by that privilege in ddl.sgml and the
description of the predefined pg_maintain role in user-manag.sgml.
This was an oversight in commit ac58465e061, which introduced
REPACK.

Add REPACK to both documentation lists, and update the corresponding
comment in aclchk.c.

Author: Shinya Kato <shinya11.kato@gmail.com>
Reviewed-by: Ewan Young <kdbase.hack@gmail.com>
Reviewed-by: Fujii Masao <masao.fujii@gmail.com>
Discussion: https://postgr.es/m/CAOzEurRJOVokiB2J8nrF569nX-ZMb0oRSB0C=yZQ17mZxd4_BQ@mail.gmail.com
Backpatch-through: 19

doc/src/sgml/ddl.sgml
doc/src/sgml/user-manag.sgml
src/backend/catalog/aclchk.c

index f9b0a43ad59b02e9debf8ab9e3ef276c058e7c67..3f3869df44e726a98744e51441c6b3ebf6a12637 100644 (file)
@@ -2538,7 +2538,8 @@ REVOKE ALL ON accounts FROM PUBLIC;
     <listitem>
      <para>
       Allows <command>VACUUM</command>, <command>ANALYZE</command>,
-      <command>CLUSTER</command>, <command>REFRESH MATERIALIZED VIEW</command>,
+      <command>CLUSTER</command>, <command>REPACK</command>,
+      <command>REFRESH MATERIALIZED VIEW</command>,
       <command>REINDEX</command>, <command>LOCK TABLE</command>,
       and database object statistics manipulation functions
       (see <xref linkend="functions-admin-statsmod"/>) on a relation.
index 0ec32700bd4d0fe1cce3a6ba825ef0fdc7fc90dd..d68dd2610121ea09ef44cd7dba82fb163dcb34b3 100644 (file)
@@ -660,6 +660,7 @@ GRANT pg_signal_backend TO admin_user;
        <link linkend="sql-vacuum"><command>VACUUM</command></link>,
        <link linkend="sql-analyze"><command>ANALYZE</command></link>,
        <link linkend="sql-cluster"><command>CLUSTER</command></link>,
+       <link linkend="sql-repack"><command>REPACK</command></link>,
        <link linkend="sql-refreshmaterializedview"><command>REFRESH MATERIALIZED VIEW</command></link>,
        <link linkend="sql-reindex"><command>REINDEX</command></link>,
        and <link linkend="sql-lock"><command>LOCK TABLE</command></link> on all
index 007ede997c57a626eaa130101376243951316732..a6e8073d02e4c27c2669594cad1502a808d604ed 100644 (file)
@@ -3419,8 +3419,8 @@ pg_class_aclmask_ext(Oid table_oid, Oid roleid, AclMode mask,
        /*
         * Check if ACL_MAINTAIN is being checked and, if so, and not already set
         * as part of the result, then check if the user is a member of the
-        * pg_maintain role, which allows VACUUM, ANALYZE, CLUSTER, REFRESH
-        * MATERIALIZED VIEW, REINDEX, and LOCK TABLE on all relations.
+        * pg_maintain role, which allows VACUUM, ANALYZE, CLUSTER, REPACK,
+        * REFRESH MATERIALIZED VIEW, REINDEX, and LOCK TABLE on all relations.
         */
        if (mask & ACL_MAINTAIN &&
                !(result & ACL_MAINTAIN) &&