Req #51869 [Com]: LDAP pagination support

From: Date: Fri, 21 May 2010 15:31:34 +0000
Subject: Req #51869 [Com]: LDAP pagination support
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-150710@lists.php.net to get a copy of this message
Edit report at http://bugs.php.net/bug.php?id=51869&edit=1

 ID:          51869
 Comment by:  jeanseb at au-fil-du dot net
 Reported by: jeanseb at au-fil-du dot net
 Summary:     LDAP pagination support
 Status:      Bogus
 Type:        Feature/Change Request
 Package:     LDAP related
 PHP Version: 5.2.13

 New Comment:

Done. 

http://bugs.php.net/bug.php?id=42060

Thanks for your answer.


Previous Comments:
------------------------------------------------------------------------
[2010-05-20 15:24:25] pajoye@php.net

Duplicate request, see #42060.

Pls keep in mind that 5.2/3 are in bug fixes mode only. If you can
update the patch to make it work against svn's trunk, then I can review,
test and apply it.

Please post any further comments in the bug #42060.

------------------------------------------------------------------------
[2010-05-20 11:37:59] jeanseb at au-fil-du dot net

Description:
------------
LDAP protocol v3 add the pagination feature to LDAP search.

Currently PHP doesn't support this.

Pierangelo Masarati <ando@OpenLDAP.org> and Iñaki Arenaza
<iarenuno@eteo.mondragon.edu> made a patch with some other features.

I extracted the pagination feature and add some phpt.

This patch is based on the PHP 5.2 branch (I will produce a trunk & php
5.3 implementation soon).


rfc2696 : http://www.ietf.org/rfc/rfc2696.txt
Original patch :
http://www.eteo.mondragon.edu/descargas/php-ldap/diff-php-src-5-2-12.patch

Test script:
---------------
$ds = ldap_connect($ldapHost, $ldapPort);

ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3);

ldap_bind($ds, $ldapUser, $ldapPass);

$cookie = '';
do {
    ldap_ctrl_paged_results($ds, $pageSize, true, $cookie);

    $result = ldap_search($ds, $dn, $filter, $justthese);

    $entries = ldap_get_entries($ds, $result);

    ldap_ctrl_paged_results_resp($ds, $result, $cookie);

} while($cookie !== null && $cookie != '');



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



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


Thread (4 messages)

« previous php.bugs (#150710) next »