[turba] Re: LDAP scope

Craig White craigwhite at azapple.com
Tue Feb 22 07:45:56 PST 2005


On Tue, 2005-02-22 at 10:25 +0100, Jan Schneider wrote:
> Zitat von Craig White <craigwhite at azapple.com>:
> 
> > I would recommend changing ldap.php though
> >
> > line 145
> >
> > replace ldap_search
> > with    ldap_list
> >
> > as it does a scope one search and not a scope sub search
> 
> Can the other LDAP users confirm that this works with their setups and 
> doesn't break anything?
> 
----
probably a bit of a 'glimpse of the obvious' for you but if you had an
entry in params

        'scope' => 'sub',

        if (!($res = @ldap_search($this->_ds, $this->_params['root'],
$filter, $attr, 0, $sizelimit))) {
            return PEAR::raiseError(sprintf(_("Query failed: (%s) %s"),
ldap_errno($this->_ds), ldap_error($this->_ds)));


and if it were...

        'scope' => 'one',

        if (!($res = @ldap_list($this->_ds, $this->_params['root'],
$filter, $attr, 0, $sizelimit))) {
            return PEAR::raiseError(sprintf(_("Query failed: (%s) %s"),
ldap_errno($this->_ds), ldap_error($this->_ds)));

Craig



More information about the turba mailing list