Fix for bug in ldapServiceLookup in libpq

From: "Albe Laurenz" <laurenz(dot)albe(at)wien(dot)gv(dot)at>
To: "pgsql-hackers" <pgsql-hackers(at)postgresql(dot)org>
Subject: Fix for bug in ldapServiceLookup in libpq
Date: 2011-05-11 14:40:49
Message-ID: D960CB61B694CF459DCFB4B0128514C20668FA0F@exadv11.host.magwien.gv.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I have found a small but annoying bug in libpq where
connection parameters are resolved via LDAP.

There is a write past the end of a malloc'ed string which causes
memory corruption. The code and the bug are originally by me :^(

The attached patch fixes the problem in HEAD.
This should be backpatched to 8.2 where the code was introduced.

Yours,
Laurenz Albe

Attachment Content-Type Size
ldapServiceLookup.patch application/octet-stream 576 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2011-05-11 14:40:58 Re: the big picture for index-only scans
Previous Message Kevin Grittner 2011-05-11 14:38:15 Re: the big picture for index-only scans