Re: ldap-bind

Graham Barr <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.ldap
Message-ID <[email protected]>
On Jun 10, 2009, at 3:07 PM, Bryan Irvine wrote:

> That's my problem then.
>
> Is there a way to check for bind failure?

Yes, see Net::LDAP::Message and Net::LDAP::Constant docs

the bind will fail, but the server will allow requests to continue as  
if the bind had not happened. ie it will treat the connection as  
anonymous

Graham.

>
> -Bryan
>
>
>
> On Wed, Jun 10, 2009 at 12:53 PM, Clif
> Harden<[email protected]> wrote:
>>
>> The bind failure will fall back to an anonymous bind, which will  
>> allow you
>> to continue to search and return attributes that an anonymous bind  
>> can see.
>>
>> Clif  Harden
>>
>>
>>
>>
>> Bryan Irvine wrote:
>>>
>>> On Wed, Jun 10, 2009 at 12:38 PM, Graham Barr<[email protected]>  
>>> wrote:
>>>
>>>>
>>>> On Jun 10, 2009, at 1:51 PM, Bryan Irvine wrote:
>>>>
>>>>
>>>>>
>>>>> I'm using ldaps and when I try to bind to a made up FqDN the  
>>>>> scripts
>>>>> still seems to be able to function.
>>>>>
>>>>> Presently I'm binding with:
>>>>> $ldaps->bind ("totalBSDN=screwDodge") or die("could not bind");
>>>>>
>>>>
>>>> Net::LDAP methods return Net::LDAP::Message objects, not true/false
>>>>
>>>> see http://search.cpan.org/~gbarr/perl-ldap-0.39/lib/Net/LDAP.pod#METHODS
>>>>
>>>
>>>
>>>
>>> Whoops! ;-)
>>>
>>> Does the bind fallback to anonymous mode if it fails? or does it not
>>> bother authenticating until a process requriing more privs is  
>>> needed?
>>> The current operation I'm testing (search) can be done with  
>>> anonymous
>>> bind just fine.
>>>
>>> -Bryan
>>>
>>>
>>
>>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.