CVE-2018-16850: SQL Injection

Published Nov 5, 2018
·
Updated

Last updated 25 August 2025

Other sources

Postgresql before versions 11.1 and 10.6 are vulnerable to SQL injection in pgupgrade and pgdump via CREATE TRIGGER ... REFERENCING. Using a purpose-crafted trigger definition, an attacker can cause arbitrary SQL statements to run, with superuser privileges, during the next pgupgrade of the database or the next pgdump dump/restore cycle. The attack requires CREATE privilege on some non-temporary schema or TRIGGER privilege on some table. This is exploitable in the default configuration, where all users have CREATE privilege on schema "public".

Red Hat

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

Launchpad

Affected Software

12 affected componentsFixes available
redhat/postgresql<11.1
11.1
redhat/postgresql<10.6
10.6
debian/postgresql-10
debian/postgresql-9.1
PostgreSQL postgresql>=10.0<10.6
PostgreSQL postgresql>=11.0<11.1
redhat Enterprise Linux=7.0
redhat Enterprise Linux=7.4
redhat Enterprise Linux=7.5
redhat Enterprise Linux=7.6
Canonical Ubuntu Linux=18.04
Canonical Ubuntu Linux=18.10

Event History

Nov 13, 2018
CVE Published
via MITRE·03:00 PM
Data Sourced
via MITRE·03:00 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·03:29 PM
RemedyDescriptionSeverityWeaknessAffected Software
Jan 11, 2024
Data Sourced
via Launchpad·10:54 PM
Description
Feb 20, 2026
Data Sourced
via Ubuntu·05:44 PM
RemedyDescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2018-16850?

The severity of CVE-2018-16850 is critical with a CVSS score of 9.8.

2

How does CVE-2018-16850 affect PostgreSQL?

CVE-2018-16850 affects PostgreSQL versions before 11.1 and 10.6.

3

How can an attacker exploit CVE-2018-16850?

An attacker can exploit CVE-2018-16850 by using a purpose-crafted trigger definition to cause arbitrary SQL statements to run with superuser privileges.

4

Which software packages are affected by CVE-2018-16850?

Software packages affected by CVE-2018-16850 include PostgreSQL versions before 11.1 and 10.6, as well as Redhat Enterprise Linux and Canonical Ubuntu Linux.

5

Where can I find more information about CVE-2018-16850?

More information about CVE-2018-16850 can be found at the following references: [Bugzilla Redhat](https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-16850), [PostgreSQL News](https://www.postgresql.org/about/news/1905/), [Ubuntu Security Notices](https://usn.ubuntu.com/3818-1/)

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203