pgsql: Fix buffer overrun after incomplete read in pullf_read_max(). - Mailing list pgsql-committers

From Noah Misch
Subject pgsql: Fix buffer overrun after incomplete read in pullf_read_max().
Date
Msg-id E1YIIVa-0008OT-KY@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Fix buffer overrun after incomplete read in pullf_read_max().

Most callers pass a stack buffer.  The ensuing stack smash can crash the
server, and we have not ruled out the viability of attacks that lead to
privilege escalation.  Back-patch to 9.0 (all supported versions).

Marko Tiikkaja

Security: CVE-2015-0243

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/1dc75515868454c645ded22d38054ec693e23ec6

Modified Files
--------------
contrib/pgcrypto/expected/pgp-info.out           |    3 ++-
contrib/pgcrypto/expected/pgp-pubkey-decrypt.out |   25 +++++++++++++++++++++
contrib/pgcrypto/mbuf.c                          |    1 +
contrib/pgcrypto/sql/pgp-pubkey-decrypt.sql      |   26 ++++++++++++++++++++++
4 files changed, 54 insertions(+), 1 deletion(-)


pgsql-committers by date:

Previous
From: Noah Misch
Date:
Subject: pgsql: Fix buffer overrun after incomplete read in pullf_read_max().
Next
From: Bruce Momjian
Date:
Subject: pgsql: to_char(): prevent accesses beyond the allocated buffer