Net::LDAP fails with latest ActiveState Perl, can be worked round by renoving INET6.pm

Similar error to that described by Glen Tanner a few weeks ago.

Recently installed a new PC with updated version of Perl::

D:\temp>perl -v
This is perl 5, version 16, subversion 3 (v5.16.3) built for
MSWin32-x64-multi-thread
[...]
Binary build 1603 [296746] provided by ActiveState http://www.ActiveState.com
Built Mar 13 2013 13:31:10

A Perl Net::LDAP application that binds to Active Directory failed
with error messages like these:
    Return code: 82
    Error code:  Bad file descriptor
    Error name:  LDAP_LOCAL_ERROR
    Error text:  An error occurred in C<Net::LDAP>

The error can be reproduced with this code:

#===============
use Net::LDAP;
use strict;
my $filter = "cn=$target\x2a";
my $ldap = Net::LDAP->new ($lhost, onerror => "die");
my $bindmesg = $ldap->bind($luser,password=>$lpass);
my $searchresult = $ldap->search( base=>$lbase, filter=>$filter, attrs=>["dn"]);
#===============

Which on older Perls finds the DNs of all AD users with names starting
with string $target, but fails on current version of Perl.
($lbase = Root path of AD directory, $lhost = AD directory server
hostname, $luser = DN of known user, $lpass = that users password)


Following some hints on other mailing lists referring to Strawberry
Perl rather than ActiveState, I renamed
C:\Perl64\site\lib\IO\Socket\INET6.pm  and it worked.

So somewhere there is a bug.

-- 
Ken Brown
0
ken
4/2/2014 5:38:43 PM
perl.ldap 1268 articles. 0 followers. Follow

1 Replies
2464 Views

Similar Articles

[PageSpeed] 2

Hi,

On Wednesday, 2. April 2014 18:38:43 k.brown@mail.bbk.ac.uk wrote:
> Similar error to that described by Glen Tanner a few weeks ago.
> 
> Recently installed a new PC with updated version of Perl::
> 
> D:\temp>perl -v
> This is perl 5, version 16, subversion 3 (v5.16.3) built for
> MSWin32-x64-multi-thread
> [...]
> Binary build 1603 [296746] provided by ActiveState
> http://www.ActiveState.com Built Mar 13 2013 13:31:10
> 
> [....]
> 
> Following some hints on other mailing lists referring to Strawberry
> Perl rather than ActiveState, I renamed
> C:\Perl64\site\lib\IO\Socket\INET6.pm  and it worked.
> 
> So somewhere there is a bug.

I concur, but I am pretty sure the error is not in perl-ldap.
perl-ldap is just one of the victims of a break between some
versions of ActiveState / Strawberry Perl / IO::Socket::INET6.

What versions of 
* perl-ldap
* IO::Socket::INET6 
are you using?

Instead of removing IPv6 support (this is what happens
if you rename/remove IO::Socket::INET6), you may try
the following:
* install IO::Socket::IP
* install latest perl-ldap

Recent perl-ldap versions prefer IO::Socket::IP over IO::Socket::INET6
when the former one is installed.
If  IO::Socket::IP does not suffer the problems that recent versions
of IO::Socket::INET6 seem to have in Windows, then everything should
work as before including IPv6 support.

Best
PEter

-- 
Peter Marschall
peter@adpm.de

0
peter
4/18/2014 11:54:31 AM
Reply:

Similar Artilces:

make Net::LDAP::LDIF more similar to Net::LDAP
Hi Graham, hi Chris, hi list, I would like to rework Net::LDAP::LDIF a bit so that its API resembles that of Net::LDAP a bit more while still keeping the traditional API. The reason for this is that in application I often need to distinguish between Net::LDAP and Net::LDAP::LDIF because some methods are only implemented on one side. I\'d like to start with a code() method that tries to mimic the Net::LDAP one and I\'d like to extend the Net::LDAP::Entry->update() method so that it takes a Net::LDAP::LDIF object as an argument. The latter one requires a...

'Can't locate Net/LDAP.pm
Hi, when I attempt to change loginmethod from DB to LDAP. I got the follow message: New value for loginmethod is invalid: Error requiring Net::LDAP: 'Can't locate Net/LDAP.pm in @INC (@INC contains: . C:/Perl/lib C:/Perl/site/lib) at (eval 28) line 3. ' Is someone can help to install Net/LDAP.pm? I use Bugzilla 2.18 in windows2003. Thanks Webber > you should do: > ppm install Net::LDAP > it's missing in the windows install doc i've added this to http://www.bugzilla.org/docs/win32install.html -byron begin-base64 644 signatu...

[Fwd: make Net::LDAP::LDIF more similar to Net::LDAP]
--------------95D5815B06BDC2BD1A0ABFEB Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit --------------95D5815B06BDC2BD1A0ABFEB Content-Type: message/rfc822 Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Mozilla-Status2: 00000000 Message-ID: <40C7B13E.8864E5A0@cs.adelaide.edu.au> Date: Thu, 10 Jun 2004 10:54:22 +1000 From: Sion Camilleri <sion@cs.adelaide.edu.au> Reply-To: sion@cs.adelaide.edu.au X-Mailer: Mozilla 4.8 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: Graham Barr <gbarr@pobox.com>...

'Can't locate Net/LDAP.pm #2
Hi, when I attempt to change loginmethod from DB to LDAP. I got the follow message: New value for loginmethod is invalid: Error requiring Net::LDAP: 'Can't locate Net/LDAP.pm in @INC (@INC contains: . C:/Perl/lib C:/Perl/site/lib) at (eval 28) line 3. ' Is someone can help to install Net/LDAP.pm? I use Bugzilla 2.18 in windows2003. Thanks Webber hi, you should do: ppm install Net::LDAP it's missing in the windows install doc Eduardo ...

Contention between Net::LDAPS.pm and CGI.pm
--Boundary-00=_YQ3aErjaD8FoC1l Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline I have a cgi we use to bind to a Sun ONE 5.2 LDAP Server to do password reset. The CGI.pm based app dynamically creates a page with an input textfield for the user's username (uid). Click 'Search' and the script binds to LDAP, retrieves the user's entry, and displays in a 2nd page. That 2nd page has the new password fields. Click 'Reset' button, the script binds to LDAP and modifies the password. Binds to ...

Net::LDAP v0.28, bug in Net::LDAP::Constant, :all not supported
Net::LDAP::Constant no longer supports the :all tag in the export list due to the switch from Exporter to a manual export routine. So, while the following: perl -MNet::LDAP::Constant=:all -e 1 worked fine in 0.2701, it now dies with the error: ":all" is not exported by the Net::LDAP::Constant module at -e line 0 Can't continue after import errors at -e line 0 BEGIN failed--compilation aborted, <DATA> line 197. The documentation for Net::LDAP::Constant still documents the ':all' tag. I am not subscribed to the list, so if some...

Fw: Re: make Net::LDAP::LDIF more similar to Net::LDAP
Am 08.06.2004 um 18:29 Uhr haben Sie geschrieben: > On 8 Jun 2004, at 16:56, peter@adpm.de wrote: > > I\'d like to start with a code() method that tries to mimic the >> Net::LDAP one and >I assume you mean better error handling ? My first goal is having a code() method in Net::LDAP::LDIF. > > I\'d like to extend the > > Net::LDAP::Entry->update() method so that it takes a > > Net::LDAP::LDIF object as an argument. The latter one > > requires a bit of work in Net::LDAP::LDIF to make it > > correct. > Not su...

Net::LDAP and Net:LDAP::LDIF read & add problems
I'm trying to read in a simple LDIF file to add an entry to my LDAP server. Here is the basic routine (extraneous details omitted for brevity and security): $ldif = Net::LDAP::LDIF->new($tmp,"r",onerror => 'warn'); $entry = $ldif->ready_entry(); $ldap = Net::LDAP->new($LDAPSERVER); $result=$ldap->bind("$binddn",password=>"$bindpass",version=>"3"); $result=$ldap->add($entry); Now, everything seems to work until I get to the $ldap->add method. From that I get various versions of the following: object...

Net::LDAP and Net:LDAP::LDIF read & add problems #2
I'm trying to read in a simple LDIF file to add an entry to my LDAP server. Here is the basic routine (extraneous details omitted for brevity and security): $ldif = Net::LDAP::LDIF->new($tmp,"r",onerror => 'warn'); $entry = $ldif->ready_entry(); $ldap = Net::LDAP->new($LDAPSERVER); $result=$ldap->bind("$binddn",password=>"$bindpass",version=>"3"); $result=$ldap->add($entry); Now, everything seems to work until I get to the $ldap->add method. From that I get various versions of the following: obj...

Fw: Re: make Net::LDAP::LDIF more similar to Net::LDAP #2
Hi, Am 09.06.2004 um 01:44 Uhr haben Sie geschrieben: > Extending Net::LDAP::Entry to update against LDIF and LDAP objects > could allow the changetype modifications to be to produced. > > This would be really useful to produce changetypes for entry objects by > updating against an LDIF object to produce the changetype LDIF required > up to synchronise entry objects. as Graham posted you can to that already now. Simply create your Net::LDAP::Entry object with the changes option set to TRUE. Having created the ::LDIF object that way you autom...

Net::LDAP.pm
Hello, Can anyone tell me why I am receiving an error can't locate Net/LDAP.pm in @ INC (@INC includes /usr/lib/perl5/5.6.1 etc, etc etc, etc. Thanks - Susan On Tue, 11 Mar 2003 at 11:49, Susan Aurand opined: SA:Hello, Can anyone tell me why I am receiving an error can't locate SA:Net/LDAP.pm in @ INC (@INC includes /usr/lib/perl5/5.6.1 etc, etc etc, SA:etc. is net::ldap installed? > Can anyone tell me why I am receiving an error can't > locate Net/LDAP.pm in @ INC (@INC includes > /usr/lib/perl5/5.6.1 etc, etc etc, etc. Yes, this means that...

Can't call method "modify" on an undefined value at /usr/lib/perl5/site_perl/5.8.5/Net/LDAP/Entry.pm line 252
Hi everyone, I'm trying to do a simple modify on a bunch of records. I search for the record, find it, and at this point, I've got it down to adding just one attribute. The error I get (on every record I try this on) is: Can't call method "modify" on an undefined value at /usr/lib/perl5/site_perl/5.8.5/Net/LDAP/Entry.pm line 252 To verify, I do a $entry->dump before and after the $entry->add, and only the added atribute is changed. I thought this might have had something to do with the ctCalUser schema, which I've had trouble with, but once I...

Net:Net:Net::LDAP::FAQ
------_=_NextPart_001_01C6429F.D89AA417 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello, Net::LDAP Net::LDAPS Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, ....) password? I don't like to write the secret password to the perl file. Best regards Barbara Wilbert ------_=_NextPart_001_01C6429F.D89AA417-- Wilbert Barbara (CI/OSI) * wrote: > Hello, > > Net::LDAP > Net::LDAPS > > Is there a possible to LDAP bind with an encrypted (SHA, SSHA, CRYPT, > ......

Net::LDAP based LDAP server available?
Hi, has anybody tried to build an LDAP server based on Net::LDAP or Convert::ASN1 yet? Thanks for any hint. Enrik ...

Net::LDAP & LDAP Decoding Error
--mvpLiMfbWzRoNl4x Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hello! I have a question about an LDAP query with Net::LDAP. I send queries to an OpenLDAP server (version 2.2.24). The queries are very simple and intended to detect already existing user entries. The code that prepares and sends the query looks like this: $filter =3D "(uid=3D".$username.")"; $filterobj =3D Net::LDAP::Filter->new($filter); $lres =3D $ldap->search( base =3D> $base, s...

Web resources about - Net::LDAP fails with latest ActiveState Perl, can be worked round by renoving INET6.pm - perl.ldap

Canada's ActiveState Cuts Cloud Deal With HP
ActiveState, a Vancouver, Canada-based cloud software firm said that it had licensed its platform-as-a-service product, called Stackato, to Hewlett-Packard. ...

ActiveState Private PaaS With Stackato 2.8
Enterprise private-PaaS gets improved LDAP controls and SPDY support

ActiveState Ships Komodo IDE 7.1 With Cloud Debugging
ActiveState has delivered Komodo 7.1, the latest release of its integrated development environment that supports a variety of programming languages ...

HP Unveils Cloud Application Platform Powered by ActiveState
... last 6 months looking for its PaaS partner for a new global OEM licensing agreement finally settling on Vancouver, British Columbia based ActiveState ...

ActiveState - Geekosystem
... after school. Such is the case of 15-year-old Danill Kulchenko , who recently sold his startup cloud-based computing company Phenona to ActiveState ...


ActiveState buys Appsecute for its social devops smarts
ActiveState , the company behind the Stackato enterprise-focused platform as a service (PaaS), is buying Appsecute, a New Zealand-based startup ...

ActiveState Buys Appsecute To Enhance PaaS With Facebook-Style Feed For Developers And IT Pros - TechCrunch ...
ActiveState, a platform-as-a-service provider, has acquired New Zealand-based Appsecute, a company that provides social monitoring tools for ...

PaaS Provider ActiveState And The Paradox Of Aligning With HP And Cloud Foundry
Platform-as-a-Service (PaaS) provider ActiveState recently scored a sweet deal with HP: It is the official PaaS for the entire HP cloud business. ...

HP acquires ActiveState’s Stackato PaaS business
HP today announced that it has agreed to buy the Stackato business from ActiveState . Terms of the deal weren’t disclosed. Stackato is private ...

Resources last updated: 1/22/2016 6:14:28 PM