[pgpool-hackers: 3586] Re: error of LDAP authentication from [pgpool-hackers:3538]

Takuma Hoshiai hoshiai at sraoss.co.jp
Tue Apr 21 17:31:37 JST 2020


Hello

Thank you for letting me know.
After checking, I find out this problem. It happend when --with-ldap and
--with-pam options were not used together.
 
I have attached fixed patch for this problem.
Please try again with this patch.

Best Regards,
Takuma Hoshiai

On Tue, 21 Apr 2020 02:17:39 +0000
周建身 <zhoujianshen at highgo.com> wrote:

> Hello
> 
> 
>     Under the directory of pgpool,I did the patch of LDAP authentication from [pgpool-hackers:3538].
> 
> The patched command which I used is,patch -p1 < pgpool_ldap_auth.patch.I got pgpool_ldap_auth.patch from [pgpool-hackers:3538].
> 
> 
> 
> The patched results are as follows
> 
> 
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file configure.ac
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file doc.ja/src/sgml/client-auth.sgml
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file doc/src/sgml/client-auth.sgml
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file src/auth/pool_auth.c
> 
> (Stripping trailing ?CRs from patch; use --binary to disable.)
> 
> patching file src/auth/pool_hba.c
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file src/include/auth/pool_hba.h
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file src/include/config.h.in
> 
> (Stripping trailing CRs from patch; use --binary to disable.)
> 
> patching file src/pgpool.spec
> 
> patch unexpectedly ends in middle of line
> 
> Hunk #1 succeeded at 103 with fuzz 1.
> 
> 
> 
> I follow the guidelines to do next operation.
> 
> 
> 
>  $ autoheader
> 
>  $ aclocal
> 
>  $ automake -a -c
> 
>  $ autoconf
> 
> 
> 
> Then,I did the configure.
> 
> 
> 
> ./configure --prefix=/opt/pgpool_3 --with-pgsql=/opt/PG12
> 
> 
> 
> Then I did the make operation which result in errors.
> 
> 
> 
> auth/pool_hba.c:758:33: error: 'uaLDAP' undeclared (first use in this function); did you mean 'uaMD5'?
> 
>   if (parsedline->auth_method == uaLDAP)
> 
>                                  ^~~~~~
> 
>                                  uaMD5
> 
> auth/pool_hba.c:758:33: note: each undeclared identifier is reported only once for each function it appears in
> 
> auth/pool_hba.c: In function 'parse_hba_auth_opt':
> 
> auth/pool_hba.c:895:23: error: 'uaLDAP' undeclared (first use in this function); did you mean 'uaMD5'?
> 
>    REQUIRE_AUTH_OPTION(uaLDAP, "ldapurl", "ldap");
> 
>                        ^
> 
> auth/pool_hba.c:320:30: note: in definition of macro 'REQUIRE_AUTH_OPTION'
> 
>   if (hbaline->auth_method != methodval) \
> 
>                               ^~~~~~~~~
> 
> Makefile:800: recipe for target 'auth/pool_hba.o' failed
> 
> 
> 
> 
> 
> I also did another configure.
> 
>  ./configure --prefix=/opt/pgpool_3 --with-pgsql=/opt/PG12 --with-ldap
> 
> 
> 
> Then I did the make operation which result in other errors.
> 
> 
> 
> auth/pool_hba.o: In function `CheckLDAPAuth':
> 
> /auth/pool_hba.c:2623: undefined reference to `recv_password_packet'
> 
> collect2: error: ld returned 1 exit status
> 
> Makefile:777: recipe for target 'pgpool' failed
> 
> make[2]: *** [pgpool] Error 1
> 
> make[2]: Leaving directory '/home/zhoujianshen/pgpool-II-4.1.1/src'
> 
> Makefile:866: recipe for target 'all-recursive' failed
> 
> make[1]: *** [all-recursive] Error 1
> 
> make[1]: Leaving directory '/home/zhoujianshen/pgpool-II-4.1.1/src'
> 
> Makefile:410: recipe for target 'all-recursive' failed
> 
> make: *** [all-recursive] Error 1
> 
> 
> 
> Could you please help me checkout what result these errors,thanks.
> 
> 
> 
> Thanks
> Best regards
> Jianshen Zhou
> 


-- 
Takuma Hoshiai <hoshiai at sraoss.co.jp>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pgpool_ldap_auth_v2.patch
Type: application/octet-stream
Size: 74769 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-hackers/attachments/20200421/754dc98a/attachment-0001.obj>


More information about the pgpool-hackers mailing list