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

Re: IO::Socket and IPv6

Thread Previous | Thread Next
From:
Quanah Gibson-Mount
Date:
March 3, 2011 10:03
Subject:
Re: IO::Socket and IPv6
Message ID:
9C23300AD2E461130619067E@[192.168.1.2]
--On Wednesday, March 02, 2011 9:56 PM -0600 Graham Barr <gbarr@pobox.com> 
wrote:

>> After a bit of debugging, the root problem is Perl's implementation of
>> inet_aton.  I've filed a bug with Perl core.
>
> I think it is partly some fault of Net::LDAP
>
> Net::LDAP will use IO::Socket::INET or IO::Socket::INET6 to connect
> depending on if the inet6 option is passed to connect
>
> ::INET will only connect to v4 addresses but I believe ::INET6 will
> connect to either. But there is no guarantee ::INET6 exists
>
> Hm, I wonder if we should just select the default connecting class by
>
> my $connect_class = eval { require IO::Socket::INET6 } ?
> "IO::Socket::INET6" : "IO::Socket::INET";

Hi Graham,

That may indeed fix Net::LDAP's behavior, but any other Perl module out 
there that ends up calling IO::Socket::INET which then goes and calls 
inet_aton has the possibility of hitting this issue.  So I do think it 
would be great if it gets fixed at the Perl core level as well. ;)

--Quanah


--

Quanah Gibson-Mount
Sr. Member of Technical Staff
Zimbra, Inc
A Division of VMware, Inc.
--------------------
Zimbra ::  the leader in open source messaging and collaboration

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