CVE-2016-0773: Buffer Overflow

Published Feb 2, 2016
·
Updated

A vulnerability was found in a way postgresql processes specially crafted regular expressions.

Purpose-crafted regular expressions elicited an integer overflow when computing a heap allocation size, and the server proceeded to write past the end of the undersized buffer. This could reliably crash the server, and we have not ruled out the viability of attacks that lead to privilege escalation. If an application accepts arbitrary regular expressions from its users, they can exploit this without otherwise having access to query the database.

Acknowledgements:

Red Hat would like to thank PostgreSQL upstream for reporting this issue. Upstream acknowledges Tom Lane and Greg Stark as the original reporters.

Other sources

PostgreSQL before 9.1.20, 9.2.x before 9.2.15, 9.3.x before 9.3.11, 9.4.x before 9.4.6, and 9.5.x before 9.5.1 allows remote attackers to cause a denial of service (infinite loop or buffer overflow and crash) via a large Unicode character range in a regular expression.

— MITRE

Affected Software

33 affected componentsFixes available
PostgreSQL postgresql<=9.1.19
PostgreSQL postgresql=9.2
PostgreSQL postgresql=9.2.1
PostgreSQL postgresql=9.2.2
PostgreSQL postgresql=9.2.3
PostgreSQL postgresql=9.2.4
PostgreSQL postgresql=9.2.5
PostgreSQL postgresql=9.2.6
PostgreSQL postgresql=9.2.7
PostgreSQL postgresql=9.2.8
PostgreSQL postgresql=9.2.9
PostgreSQL postgresql=9.2.10
PostgreSQL postgresql=9.2.11
PostgreSQL postgresql=9.2.12
PostgreSQL postgresql=9.2.13
PostgreSQL postgresql=9.2.14
PostgreSQL postgresql=9.4
PostgreSQL postgresql=9.4.1
PostgreSQL postgresql=9.4.2
PostgreSQL postgresql=9.4.3
PostgreSQL postgresql=9.4.4
PostgreSQL postgresql=9.4.5
PostgreSQL postgresql=9.5
Canonical Ubuntu Linux=12.04
Canonical Ubuntu Linux=14.04
Canonical Ubuntu Linux=15.10
Debian Debian Linux=7.0
Debian Debian Linux=8.0
redhat/postgresql<9.5.1
9.5.1
redhat/postgresql<9.4.6
9.4.6
redhat/postgresql<9.3.11
9.3.11
redhat/postgresql<9.2.15
9.2.15
redhat/postgresql<9.1.20
9.1.20

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/postgresql to a version that resolves this vulnerability.

    Fixed in 9.5.1
  2. Upgrade

    Upgrade redhat/postgresql to a version that resolves this vulnerability.

    Fixed in 9.4.6
  3. Upgrade

    Upgrade redhat/postgresql to a version that resolves this vulnerability.

    Fixed in 9.3.11
  4. Upgrade

    Upgrade redhat/postgresql to a version that resolves this vulnerability.

    Fixed in 9.2.15
  5. Upgrade

    Upgrade redhat/postgresql to a version that resolves this vulnerability.

    Fixed in 9.1.20

Event History

Feb 2, 2016
Data Sourced
via Red Hat·07:43 AM
DescriptionSeverityAffected Software
Feb 17, 2016
CVE Published
via MITRE·03:00 PM
Data Sourced
via MITRE·03:00 PM
Description
Data Sourced
03:59 PM
DescriptionSeverityWeaknessAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2016-0773?

CVE-2016-0773 has been classified as a denial of service vulnerability that can crash PostgreSQL instances.

2

How do I fix CVE-2016-0773?

To fix CVE-2016-0773, upgrade PostgreSQL to versions 9.1.20, 9.2.15, 9.3.11, 9.4.6, or 9.5.1 or later.

3

What are the affected versions for CVE-2016-0773?

CVE-2016-0773 affects PostgreSQL versions prior to 9.1.20, 9.2.x versions before 9.2.15, 9.3.x versions before 9.3.11, 9.4.x versions before 9.4.6, and 9.5.x versions before 9.5.1.

4

Who can exploit CVE-2016-0773?

Remote attackers can exploit CVE-2016-0773 by sending specially crafted regular expressions to a vulnerable PostgreSQL server.

5

What is the impact of CVE-2016-0773?

The impact of CVE-2016-0773 is a denial of service condition that results in the PostgreSQL server entering an infinite loop or experiencing a buffer overflow, leading to a crash.

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