Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitb793d6a

Browse files
committed
Document clashes between logical replication and untrusted users.
Back-patch to v10, which introduced logical replication.Security:CVE-2020-14349
1 parentdd5d995 commitb793d6a

File tree

1 file changed

+19
-3
lines changed

1 file changed

+19
-3
lines changed

‎doc/src/sgml/logical-replication.sgml

Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -495,11 +495,27 @@
495495
<sect1 id="logical-replication-security">
496496
<title>Security</title>
497497

498+
<para>
499+
A user able to modify the schema of subscriber-side tables can execute
500+
arbitrary code as a superuser. Limit ownership
501+
and <literal>TRIGGER</literal> privilege on such tables to roles that
502+
superusers trust. Moreover, if untrusted users can create tables, use only
503+
publications that list tables explicitly. That is to say, create a
504+
subscription <literal>FOR ALL TABLES</literal> only when superusers trust
505+
every user permitted to create a non-temp table on the publisher or the
506+
subscriber.
507+
</para>
508+
498509
<para>
499510
The role used for the replication connection must have
500-
the <literal>REPLICATION</literal> attribute (or be a superuser). Access for the role must be
501-
configured in <filename>pg_hba.conf</filename> and it must have the
502-
<literal>LOGIN</literal> attribute.
511+
the <literal>REPLICATION</literal> attribute (or be a superuser). If the
512+
role lacks <literal>SUPERUSER</literal> and <literal>BYPASSRLS</literal>,
513+
publisher row security policies can execute. If the role does not trust
514+
all table owners, include <literal>options=-crow_security=off</literal> in
515+
the connection string; if a table owner then adds a row security policy,
516+
that setting will cause replication to halt rather than execute the policy.
517+
Access for the role must be configured in <filename>pg_hba.conf</filename>
518+
and it must have the <literal>LOGIN</literal> attribute.
503519
</para>
504520

505521
<para>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp