Bug 1865744 (CVE-2020-14349)

Summary: CVE-2020-14349 postgresql: Uncontrolled search path element in logical replication
Product: [Other] Security Response Reporter: Dhananjay Arunesh <darunesh>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: aboyko, aileenc, akoufoud, alazarot, almorale, anon.amish, anstephe, asakala, asoldano, atangrin, avibelli, bbaranow, bgeorges, bmaxwell, brian.stansberry, cdewolf, chazlett, clement.escoffier, dandread, darran.lofthouse, databases-maint, dblechte, devrim, dfediuck, dkreling, dosoudil, drieden, eedri, eleandro, etirelli, ggaughan, gmalinko, gsmet, hhorak, hvyas, ibek, iweiss, janstey, jawilson, jbalunas, jdobes, jlyle, jmlich83, jochrist, jorton, jpallich, jperkins, jstanek, jstastny, jwon, krathod, kverlaen, kwills, lgao, lthon, mgoldboi, michal.skrivanek, mike, mnovotny, msochure, msvehla, mszynkie, nwallace, panovotn, paradhya, pgallagh, pjindal, pkajaba, pkubat, pmackay, praiskup, psotirop, puebele, rguimara, rrajasek, rruss, rstancel, rsvoboda, rsynek, sbiarozk, sbonazzo, sdaley, sdouglas, security-response-team, sherold, smaestri, tgl, tkasparek, tom.jenkinson, vbellur, yturgema
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: postgresql 12.4, postgresql 11.9, postgresql 10.14 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in PostgreSQL, where it did not properly sanitize the search_path during logical replication. This flaw allows an authenticated attacker to use this flaw in an attack similar to CVE-2018-1058 to execute an arbitrary SQL command in the user's context for replication. The highest threat from this vulnerability is to confidentiality, integrity, as well as system availability.
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-09-08 13:19:28 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1867076, 1867077, 1867078, 1867079, 1867508, 1867509, 1868662, 1868663, 1868665, 1868667, 1872153, 1877200, 1881779, 1887758, 1901551, 1901552, 1909710, 1909711, 1910651    
Bug Blocks: 1865747    

Description Dhananjay Arunesh 2020-08-04 03:48:13 UTC
The PostgreSQL search_path setting determines schemas searched for tables, functions, operators, etc.  The CVE-2018-1058 fix caused most PostgreSQL-provided client applications to sanitize search_path, but logical replication continued to leave search_path unchanged.  Users of a replication publisher or subscriber database can create objects in the "public" schema and harness them to execute arbitrary SQL functions under the identity running replication, often a superuser.  Installations having adopted a documented "secure schema usage pattern" are not vulnerable.

Comment 7 Marian Rehak 2020-08-13 12:29:52 UTC
Created postgresql tracking bugs for this issue:

Affects: fedora-all [bug 1868662]


Created postgresql:10/postgresql tracking bugs for this issue:

Affects: fedora-all [bug 1868663]


Created postgresql:11/postgresql tracking bugs for this issue:

Affects: fedora-all [bug 1868665]


Created postgresql:12/postgresql tracking bugs for this issue:

Affects: fedora-all [bug 1868667]

Comment 10 Hardik Vyas 2020-09-08 08:07:43 UTC
Statement:

In Red Hat Gluster Storage 3, PostgreSQL was shipped as a part of Red Hat Gluster Storage Console that is no longer supported for use with Red Hat Gluster Storage 3.5. Red Hat Gluster Storage Web Administration is now the recommended monitoring tool for Red Hat Storage Gluster clusters.

Comment 11 errata-xmlrpc 2020-09-08 09:49:40 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2020:3669 https://access.redhat.com/errata/RHSA-2020:3669

Comment 12 Product Security DevOps Team 2020-09-08 13:19:28 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2020-14349

Comment 17 errata-xmlrpc 2020-11-16 09:17:41 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 7
  Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.7 EUS

Via RHSA-2020:5110 https://access.redhat.com/errata/RHSA-2020:5110

Comment 20 errata-xmlrpc 2020-11-16 12:09:15 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 7
  Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.7 EUS

Via RHSA-2020:5112 https://access.redhat.com/errata/RHSA-2020:5112

Comment 21 errata-xmlrpc 2020-12-17 15:58:01 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2020:5620 https://access.redhat.com/errata/RHSA-2020:5620

Comment 22 errata-xmlrpc 2020-12-22 09:26:59 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8.0 Update Services for SAP Solutions

Via RHSA-2020:5664 https://access.redhat.com/errata/RHSA-2020:5664

Comment 24 errata-xmlrpc 2021-01-18 09:58:54 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8.2 Extended Update Support

Via RHSA-2021:0163 https://access.redhat.com/errata/RHSA-2021:0163

Comment 25 errata-xmlrpc 2021-01-18 16:19:12 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8.1 Extended Update Support

Via RHSA-2021:0166 https://access.redhat.com/errata/RHSA-2021:0166

Comment 26 errata-xmlrpc 2021-03-25 12:16:17 UTC
This issue has been addressed in the following products:

  Red Hat Virtualization 4 for Red Hat Enterprise Linux 8

Via RHSA-2021:0988 https://access.redhat.com/errata/RHSA-2021:0988