Re: Zlib vulnerability heads-up.

From: John Gray <jgray(at)azuli(dot)co(dot)uk>
To: Lamar Owen <lamar(dot)owen(at)wgcr(dot)org>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Zlib vulnerability heads-up.
Date: 2002-03-12 17:18:35
Message-ID: 1015953519.751.7.camel@adzuki
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

On Tue, 2002-03-12 at 16:05, Lamar Owen wrote:
> As PostgreSQL uses the zlib library (for TOAST?), this is a headsup that a
> bug has been found in the zlib library that could cause data corruption or a
> security breach.
>

True enough, ldd on my system says that postgres is linked against zlib,
but I knew that TOAST didn't use it (it uses
src/backend/utils/adt/pg_lzcompress.c), so what does?

After a quick look, I offer the following summary:

"zlib" is listed as a loadable module in PL/Python (but I don't know
whether this is related to the same zlib at all)

zlib.h *is* used by the "custom" format of pg_dump.

Maybe I'm missing something, though - I just did a grep for "zlib" and
HAVE_LIBZ through the source.

This also suggests that the postgres backend needn't be linked against
zlib at all, if pg_dump is the only utility using it.

The risk from this vulnerability is that someone receiving a dump in
custom format and using pg_restore on it might be at risk of a trojan
attack - but this seems like a very slim risk (how many people would
attempt to load a data dump from an untrusted source into their DB?).

Nonetheless, it's useful to know this (and it also means I've spotted
the (possibly) unnecessary library link :)

Regards

John

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Jeff Martin 2002-03-12 17:18:53 Re: Can't get ODBC from Windows to Linux/Postgres to work, SOLVED!
Previous Message Lance Ellinghaus 2002-03-12 17:12:29 Exclusive Row access???

Browse pgsql-hackers by date

  From Date Subject
Next Message Luis Alberto Amigo Navarro 2002-03-12 17:45:12 bad performance on irix
Previous Message Lance Ellinghaus 2002-03-12 17:12:29 Exclusive Row access???