# CVE-2018-16850: libecpg6: postgresql before versions 11.1, 10.6 is vulnerable to a to SQL injection in pg_upgrade and pg_dump via CREATE TRIGGE...

CVE-2018-16850 is fixed in 12 products on 1 platform, first by libecpg-compat3 10.6-0ubuntu0.18.04.1, released November 7, 2018. It is not reported as exploited. Patch Radar priority: Routine.

- Web page: https://patchblox.com/security/cve/CVE-2018-16850
- Priority: Routine
- CVSS: n/a (Medium)
- EPSS: 0.0515
- CISA KEV: not listed
- Exploited (vendor report): no
- Publicly disclosed: no
- Published: Nov 7, 2018

## Description

postgresql before versions 11.1, 10.6 is vulnerable to a to SQL injection in pg_upgrade and pg_dump via CREATE TRIGGER ... REFERENCING. Using a purpose-crafted trigger definition, an attacker can cause arbitrary SQL statements to run, with superuser privileges.

## Where it's fixed

| Platform | Product | Fixed in | Fix | Released |
|---|---|---|---|---|
| Linux | libecpg-compat3 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [libecpg-compat3 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-libecpg-compat3-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | libecpg6 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [libecpg6 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-libecpg6-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | libpgtypes3 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [libpgtypes3 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-libpgtypes3-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | libpq5 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [libpq5 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-libpq5-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-client-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-client-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-client-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-doc-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-doc-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-doc-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-plperl-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-plperl-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-plperl-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-plpython-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-plpython-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-plpython-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-plpython3-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-plpython3-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-plpython3-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-pltcl-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-pltcl-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-pltcl-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |
| Linux | postgresql-server-dev-10 Ubuntu 18.04.6 LTS (bionic) | 10.6-0ubuntu0.18.04.1 | [postgresql-server-dev-10 10.6-0ubuntu0.18.04.1](https://patchblox.com/security/data/fix/linux/ubuntu-bionic-postgresql-server-dev-10-10.6-0ubuntu0.18.04.1.md) | Nov 7, 2018 |

---

Data as of 2026-11-07T18:46:35Z UTC. Source: Patchblox Patch Radar (https://patchblox.com/security/patch-radar). Patchblox finds out-of-date software on Windows, macOS and Linux and updates it through release rings: https://patchblox.com/demo

Free to use with attribution: show "Data: Patchblox Patch Radar" with a link to https://patchblox.com/security/patch-radar. Terms, including what needs a written agreement: https://patchblox.com/security/patch-radar/use-the-data

Product names, logos and trademarks shown on Patch Radar belong to their respective owners. They are used only to identify the software each security fix applies to and to help readers find their platform. Their use does not imply any affiliation with, or endorsement by, those owners, and Patchblox is not affiliated with any of them.
