Re: [HACKERS] Getting error message with latest PG source on Windows. - Mailing list pgsql-hackers

From Thomas Munro
Subject Re: [HACKERS] Getting error message with latest PG source on Windows.
Date
Msg-id CAEepm=3VCmKn9y4x7H2W49T4awEfAKQkgw9izdjC2y_DyH8AJA@mail.gmail.com
Whole thread Raw
In response to [HACKERS] Getting error message with latest PG source on Windows.  (Ashutosh Sharma <ashu.coek88@gmail.com>)
Responses Re: [HACKERS] Getting error message with latest PG source on Windows.  (Thomas Munro <thomas.munro@enterprisedb.com>)
List pgsql-hackers
On Wed, Sep 13, 2017 at 8:58 PM, Ashutosh Sharma <ashu.coek88@gmail.com> wrote:
> I am getting the following error message when trying to build latest
> PG source on Windows,
>
> Error 1 error C2065: 'LDAP_NO_ATTRS' : undeclared identifier
> C:\Users\ashu\pgsql\src\backend\libpq\auth.c 2468
>
> I think, it got introduced in the following git commit,
>
> commit 83aaac41c66959a3ebaec7daadc4885b5f98f561
> Author: Peter Eisentraut <peter_e@gmx.net>
> Date:   Tue Sep 12 09:46:14 2017 -0400
>
>  Allow custom search filters to be configured for LDAP auth.
>
> Please ignore this email if this issue has already been reported.

Hmm.  LDAP_NO_ATTRS was an addition to the patch discussed here:

https://www.postgresql.org/message-id/7fcac549-0051-34c8-0d62-63b921029f20%402ndquadrant.com

Googling around I see some indications that the macro may not be
defined in all implementations and that some other projects test if
it's defined:

https://github.com/spinn3r/squid-deb/blob/master/squid-2.7.STABLE9/helpers/basic_auth/LDAP/squid_ldap_auth.c#L160

It looks like that's OK because it's required to have the value "1.1":

https://tools.ietf.org/html/rfc4511
     3. A list containing only the OID "1.1" indicates that no        attributes are to be returned.  If "1.1" is
providedwith other        attributeSelector values, the "1.1" attributeSelector is        ignored.  This OID was chosen
becauseit does not (and can not)        correspond to any attribute in use.
 

It seems like we need to do that.

-- 
Thomas Munro
http://www.enterprisedb.com


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

pgsql-hackers by date:

Previous
From: Amit Langote
Date:
Subject: Re: [HACKERS] Re: [COMMITTERS] pgsql: Use MINVALUE/MAXVALUE insteadof UNBOUNDED for range partition b
Next
From: Alvaro Herrera
Date:
Subject: Re: [HACKERS] Patches that don't apply or don't compile: 2017-09-12