develooper Front page | perl.ldap | Postings from March 2011

Re: LDAP Search for all attributes of a DN

Thread Previous | Thread Next
From:
Christopher Bongaarts
Date:
March 5, 2011 12:37
Subject:
Re: LDAP Search for all attributes of a DN
Message ID:
4D72688A.7030206@umn.edu
Brian Gaber wrote:
> I have tried these two Net::LDAP approaches, but $numEnt is zero in both cases:
> 
> $mesg = $ldap->search( base => $dn );
> $numEnt = $mesg->count;
> 
> $mesg = $ldap->search ( base => $dn, scope => 'base',);
> $numEnt = $mesg->count;
> 
> A command line ldapsearch like so works fine:
> 
> ldapsearch -h my_ldap_server -x -b "fully qualfied dn"

Try using your second attempt but add a filter of "(objectClass=*)".

-- 
%%  Christopher A. Bongaarts   %%  cab@umn.edu          %%
%%  OIT - Identity Management  %%  http://umn.edu/~cab  %%
%%  University of Minnesota    %%  +1 (612) 625-1809    %%

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About