Skip to content
OpenAdvisories
Unscored CVE-2022-2625 EUVD-2022-34872GHSA-m7mv-m566-78j6

A vulnerability was found in PostgreSQL. This attack requires permission to create non-temporary objects in at least one schema, the abilit…

Published Aug 18, 2022 · Updated Nov 2, 2026 · Assigned by redhat

Description

A vulnerability was found in PostgreSQL. This attack requires permission to create non-temporary objects in at least one schema, the ability to lure or wait for an administrator to create or update an affected extension in that schema, and the ability to lure or wait for a victim to use the object targeted in CREATE OR REPLACE or CREATE IF NOT EXISTS. Given all three prerequisites, this flaw allows an attacker to run arbitrary code as the victim role, which may be a superuser.

Affected products

VendorProductAffectedFixed
— postgresql postgresql 14.5, postgresql 13.8, postgresql 12.12, postgresql 11.17, postgresql 10.22 —

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 11 postgresql-13 13.8-0+deb11u1 —
Debian 10 postgresql-11 11.17-0+deb10u1 DLA-3072-1
ReleasePackageFixed inAdvisory
Ubuntu 22.04 LTS postgresql-14 14.5-0ubuntu0.22.04.1 USN-5571-1
Ubuntu 20.04 LTS postgresql-12 12.12-0ubuntu0.20.04.1 USN-5571-1
Ubuntu 18.04 LTS postgresql-10 10.22-0ubuntu0.18.04.1 USN-5571-1
Show 2 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu Pro 16.04 LTS postgresql-9.5 No fix yet —
Ubuntu Pro 14.04 LTS postgresql-9.3 No fix yet —
ReleasePackageFixed inAdvisory
RHEL 9 postgresql +13 13.10-1.el9_1 RHSA-2023:1693
RHEL 8 pg_repack 1.4.6-3.module+el8.5.0+11354+78b3c9c5 RHSA-2023:1576, RHSA-2022:7128
RHEL 8 pgaudit 1.4.0-5.module+el8.5.0+11354+78b3c9c5 RHSA-2023:1576, RHSA-2022:7128
RHEL 8 postgres-decoderbufs 0.10.0-2.module+el8.4.0+8873+b821c30a RHSA-2023:1576, RHSA-2022:7128
RHEL 8 postgresql +12 10.23-1.module+el8.7.0+17280+3a452e1f RHSA-2023:1576, RHSA-2023:0113, RHSA-2022:7128
RHEL 3 rh-postgresql10-postgresql +13 10.23-1.el7 RHSA-2023:0160
Show 8 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
RHEL 9.0 EUS postgresql +10 13.13-1.el9_0 RHSA-2023:7545
RHEL 8.6 EUS pg_repack 1.4.6-3.module+el8.5.0+11357+bcc62552 RHSA-2023:7580
RHEL 8.6 EUS pgaudit 1.5.0-1.module+el8.4.0+8873+b821c30a RHSA-2023:7580
RHEL 8.6 EUS postgres-decoderbufs 0.10.0-2.module+el8.4.0+8873+b821c30a RHSA-2023:7580
RHEL 8.6 EUS postgresql +12 13.13-1.module+el8.6.0+20665+ba8c5a93 RHSA-2023:7580
RHEL 8.4 TUS pgaudit 1.4.0-6.module+el8.4.0+11288+c193d6d7 RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 TUS postgres-decoderbufs 0.10.0-2.module+el8.4.0+8873+b821c30a RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 TUS postgresql +12 12.17-1.module+el8.4.0+20773+7c41d490 RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 E4S pgaudit 1.4.0-6.module+el8.4.0+11288+c193d6d7 RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 E4S postgres-decoderbufs 0.10.0-2.module+el8.4.0+8873+b821c30a RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 E4S postgresql +12 12.17-1.module+el8.4.0+20773+7c41d490 RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 AUS pgaudit 1.4.0-6.module+el8.4.0+11288+c193d6d7 RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 AUS postgres-decoderbufs 0.10.0-2.module+el8.4.0+8873+b821c30a RHSA-2023:7695, RHSA-2023:7694
RHEL 8.4 AUS postgresql +12 12.17-1.module+el8.4.0+20773+7c41d490 RHSA-2023:7695, RHSA-2023:7694
RHEL 8.2 TUS pgaudit 1.4.0-4.module+el8.2.0+9043+1dbb5661 RHSA-2023:7667
RHEL 8.2 TUS postgres-decoderbufs 0.10.0-2.module+el8.2.0+9043+1dbb5661 RHSA-2023:7667
RHEL 8.2 TUS postgresql +12 12.17-1.module+el8.2.0+20720+50ffbc0b RHSA-2023:7667
RHEL 8.2 E4S pgaudit 1.4.0-4.module+el8.2.0+9043+1dbb5661 RHSA-2023:7667
RHEL 8.2 E4S postgres-decoderbufs 0.10.0-2.module+el8.2.0+9043+1dbb5661 RHSA-2023:7667
RHEL 8.2 E4S postgresql +12 12.17-1.module+el8.2.0+20720+50ffbc0b RHSA-2023:7667
RHEL 8.2 AUS pgaudit 1.4.0-4.module+el8.2.0+9043+1dbb5661 RHSA-2023:7667
RHEL 8.2 AUS postgres-decoderbufs 0.10.0-2.module+el8.2.0+9043+1dbb5661 RHSA-2023:7667
RHEL 8.2 AUS postgresql +12 12.17-1.module+el8.2.0+20720+50ffbc0b RHSA-2023:7667

AlmaLinux

Errata ↗
ReleasePackageFixed inAdvisory
AlmaLinux 9 postgresql +13 13.10-1.el9_1 ALSA-2023:1693
AlmaLinux 8 pg_repack 1.4.6-3.module_el8.6.0+2760+1746ec94 ALSA-2023:1576, ALSA-2022:7128
AlmaLinux 8 pgaudit 1.4.0-5.module_el8.6.0+2758+4f4474df ALSA-2023:1576, ALSA-2022:7128
AlmaLinux 8 postgres-decoderbufs 0.10.0-2.module_el8.6.0+2760+1746ec94 ALSA-2023:1576, ALSA-2022:7128
AlmaLinux 8 postgresql +12 10.23-1.module_el8.7.0+3379+54d21c26 ALSA-2023:1576, ALSA-2023:0113, ALSA-2022:7128

Rocky Linux

Errata ↗
ReleasePackageFixed inAdvisory
Rocky Linux 8 pg_repack 1.4.6-3.module+el8.5.0+684+c3892ef9 RLSA-2023:1576, RLSA-2022:7128
Rocky Linux 8 pgaudit 1.4.0-5.module+el8.5.0+686+20453ecc RLSA-2023:1576, RLSA-2022:7128
Rocky Linux 8 postgres-decoderbufs 0.10.0-2.module+el8.4.0+424+71d47d9a RLSA-2023:1576, RLSA-2022:7128
Rocky Linux 8 postgresql 10.23-1.module+el8.7.0+1118+c6c6f44a RLSA-2023:1576, RLSA-2023:0113, RLSA-2022:7128
ReleasePackageFixed inAdvisory
SLES 15 SP4 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SLES 15 SP4 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-2, SUSE-SU-2022:2989-1
SLES 15 SP3 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLES 15 SP3 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SLES 15 SP3 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SLES 15 SP3 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SLES 15 SP2 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLES 15 SP2 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SLES 15 SP2 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SLES 15 SP2 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SLES 15 SP1 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SLES 15 SP1 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLES 15 SP1 postgresql12 12.12-150100.3.33.1 SUSE-SU-2022:2958-1
SLES 15 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SLES 15 postgresql10 10.22-150000.4.42.1 SUSE-SU-2022:2893-1
Show 19 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES 12 SP5 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SLES 12 SP5 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SLES 12 SP5 postgresql12 12.12-3.30.2 SUSE-SU-2022:3193-1
SLES 12 SP5 postgresql13 13.8-3.24.1 SUSE-SU-2022:2912-1
SLES 12 SP5 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SLES 12 SP4 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SLES 12 SP4 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SLES 12 SP4 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SLES 12 SP3 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SLES 12 SP3 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SLES 12 SP3 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SLES 12 SP2 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SLES 12 SP2 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SLES 12 SP2 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SLES for SAP 15 SP2 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLES for SAP 15 SP2 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SLES for SAP 15 SP2 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SLES for SAP 15 SP2 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SLES for SAP 15 SP1 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SLES for SAP 15 SP1 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLES for SAP 15 SP1 postgresql12 12.12-150100.3.33.1 SUSE-SU-2022:2958-1
SLES for SAP 15 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SLES for SAP 15 postgresql10 10.22-150000.4.42.1 SUSE-SU-2022:2893-1
SLES for SAP 12 SP5 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SLES for SAP 12 SP5 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SLES for SAP 12 SP5 postgresql12 12.12-3.30.2 SUSE-SU-2022:3193-1
SLES for SAP 12 SP5 postgresql13 13.8-3.24.1 SUSE-SU-2022:2912-1
SLES for SAP 12 SP5 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SLES for SAP 12 SP4 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SLES for SAP 12 SP4 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SLES for SAP 12 SP4 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SLE HPC 15 SP2 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLE HPC 15 SP2 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SLE HPC 15 SP2 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SLE HPC 15 SP2 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SLE HPC 15 SP1 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SLE HPC 15 SP1 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SLE HPC 15 SP1 postgresql12 12.12-150100.3.33.1 SUSE-SU-2022:2958-1
SLE HPC 15 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SLE HPC 15 postgresql10 10.22-150000.4.42.1 SUSE-SU-2022:2893-1
SUSE OpenStack Cloud Crowbar 9 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SUSE OpenStack Cloud Crowbar 9 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SUSE OpenStack Cloud Crowbar 9 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SUSE OpenStack Cloud 9 postgresql 14-4.17.2 SUSE-SU-2022:3193-1
SUSE OpenStack Cloud 9 postgresql10 10.22-4.31.1 SUSE-SU-2022:2914-1
SUSE OpenStack Cloud 9 postgresql14 14.5-3.14.9 SUSE-SU-2022:3269-1
SUSE Manager Server 4.1 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SUSE Manager Server 4.1 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SUSE Manager Server 4.1 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SUSE Manager Server 4.1 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SUSE Manager Retail Branch Server 4.1 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SUSE Manager Retail Branch Server 4.1 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SUSE Manager Retail Branch Server 4.1 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SUSE Manager Retail Branch Server 4.1 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SUSE Manager Proxy 4.1 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SUSE Manager Proxy 4.1 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SUSE Manager Proxy 4.1 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SUSE Manager Proxy 4.1 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SUSE Enterprise Storage 7 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SUSE Enterprise Storage 7 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
SUSE Enterprise Storage 7 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
SUSE Enterprise Storage 7 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
SUSE Enterprise Storage 6 postgresql 12.0.1-150000.8.19.1 SUSE-SU-2022:2893-1
SUSE Enterprise Storage 6 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
SUSE Enterprise Storage 6 postgresql12 12.12-150100.3.33.1 SUSE-SU-2022:2958-1
ReleasePackageFixed inAdvisory
openSUSE Tumbleweed postgresql10 10.22-1.1 openSUSE-SU-2024:12264-1
openSUSE Tumbleweed postgresql11 11.17-1.1 openSUSE-SU-2024:12265-1
openSUSE Tumbleweed postgresql12 12.12-1.1 openSUSE-SU-2024:12266-1
openSUSE Tumbleweed postgresql13 13.8-1.1 openSUSE-SU-2024:12267-1
openSUSE Tumbleweed postgresql14 14.5-1.1 openSUSE-SU-2024:12268-1
openSUSE Leap 15.4 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
openSUSE Leap 15.4 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
openSUSE Leap 15.4 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
openSUSE Leap 15.4 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
openSUSE Leap 15.3 postgresql10 10.22-150100.8.50.1 SUSE-SU-2022:2946-1
openSUSE Leap 15.3 postgresql12 12.12-150200.8.35.1 SUSE-SU-2022:2988-1
openSUSE Leap 15.3 postgresql13 13.8-150200.5.31.1 SUSE-SU-2022:2987-1
openSUSE Leap 15.3 postgresql14 14.5-150200.5.17.1 SUSE-SU-2022:2989-1
ReleasePackageFixed inAdvisory
Alpine v3.20 postgresql14 +1 14.5-r0 —
Alpine v3.19 postgresql13 13.8-r0 —
Alpine v3.19 postgresql14 +1 14.5-r0 —
Alpine v3.18 postgresql12 12.12-r0 —
Alpine v3.18 postgresql13 13.8-r0 —
Alpine v3.18 postgresql14 +1 14.5-r0 —
Alpine v3.17 postgresql12 12.12-r0 —
Alpine v3.17 postgresql13 13.8-r0 —
Alpine v3.17 postgresql14 +1 14.5-r0 —
Alpine v3.16 postgresql12 12.12-r0 —
Alpine v3.16 postgresql13 13.8-r0 —
Alpine v3.16 postgresql14 14.5-r0 —
Show 3 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Alpine v3.15 postgresql12 12.12-r0 —
Alpine v3.15 postgresql13 13.8-r0 —
Alpine v3.15 postgresql14 14.5-r0 —
Alpine v3.14 postgresql 13.8-r0 —
Alpine v3.13 postgresql 13.8-r0 —

Azure Linux

ReleasePackageFixed inAdvisory
Azure Linux 2 (CBL-Mariner) postgresql 14.5-1 —

Oracle Linux

ReleasePackageFixed inAdvisory
Oracle Linux 9 postgresql +13 13.10-1.el9_1 ELSA-2023-1693
Oracle Linux 8 pg_repack 1.4.6-3.module+el8.5.0+20333+86306fc7 ELSA-2023-1576, ELSA-2022-7128
Oracle Linux 8 pgaudit 1.4.0-5.module+el8.5.0+20333+86306fc7 ELSA-2023-1576, ELSA-2022-7128
Oracle Linux 8 postgres-decoderbufs 0.10.0-2.module+el8.4.0+20016+06fd4df3 ELSA-2023-1576, ELSA-2022-7128
Oracle Linux 8 postgresql +12 10.23-1.module+el8.7.0+20896+16771be9 ELSA-2023-1576, ELSA-2023-0113, ELSA-2022-7128

Advisories 41

References