Req #69471 [Com]: php-ldap is using deprecated ldap functions

From: Date: Tue, 03 Nov 2015 04:56:07 +0000
Subject: Req #69471 [Com]: php-ldap is using deprecated ldap functions
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-196990@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=69471&edit=1

 ID:                 69471
 Comment by:         mcmic@php.net
 Reported by:        come dot bernigaud at opensides dot be
 Summary:            php-ldap is using deprecated ldap functions
 Status:             Assigned
 Type:               Feature/Change Request
 Package:            LDAP related
 PHP Version:        5.6.8RC1
 Assigned To:        mcmic
 Block user comment: N
 Private report:     N

 New Comment:

Ok, some of the bug report you mentioned were misleading, what is broken is using host:port, using a
full ldap URI like ldap://host:port works as expected.

I’m gonna ask on the ML but this does not seem like a big regression to me as the use of
host:port was not tested by the tests and not authorized by the documentation. (But it does seem to
break existing code, so I’m not sure)


Previous Comments:
------------------------------------------------------------------------
[2015-11-03 04:10:54] mcmic@php.net

It definitely seems related, this was not intended.
What I don’t get is that there is a test for this: https://github.com/php/php-src/blob/PHP-5.6/ext/ldap/tests/ldap_connect_variation.phpt
And at the time it was passing. I’m gonna build last git and try to see if it passes.

------------------------------------------------------------------------
[2015-10-29 11:31:11] blizzz at owncloud dot com

Is this related to https://github.com/php/php-src/commit/e7af0fe1eb89e40671e86a588aa1b78607b85461
?

It turns out that some usages of ldap_connect now fail to work (e.g. https://www.netways.org/issues/2931,
https://dev.icinga.org/issues/9298, https://github.com/owncloud/core/issues/20020).
Is this as intended?

------------------------------------------------------------------------
[2015-06-17 13:54:23] mcmic@php.net

This first patch has been pushed.
All obsolete functions should be removed so that we can remove the -DLDAP_DEPRECATED=1 option

------------------------------------------------------------------------
[2015-04-16 17:04:02] come dot bernigaud at opensides dot be

Description:
------------
PHP-LDAP is using several deprecated ldap functions from openldap, the attached patch replace
these calls by calls the new functions.
I did not remove the -DLDAP_DEPRECATED=1 because there are still some use of deprecated functions
after the patch.
This patch is derivated from http://markmail.org/message/66qafbxgaztux6df
, but I removed the parts which are not surrounded by #ifdef LDAP_API_FEATURE_X_OPENLDAP to be safe.



------------------------------------------------------------------------



--
Edit this bug report at https://bugs.php.net/bug.php?id=69471&edit=1


Thread (8 messages)

« previous php.bugs (#196990) next »