Perl, ip6 and XML RPC

Frédéric Perrin

Usenet Archive
Joined
Feb 5, 2010
Messages
9
Reaction score
0
Hello list,

I want to talk to an XML RPC service over ip6 (the server doesn't listen over ip4). However, with the three modules I tried so far (XML::RPC, RPC::XML, Frontier::RPC::Client), it tries to do the request over ip4, even though the hostname I gave only resolve to ip6. I know for a fact that it should work, as the same script in Python works.

Actually, all of this is happening in fBSD jails ; if I "tcpdump -v -i lo0 port 6800", I see the request going to some other ip4 (the ip4 address of the jail in which the Perl script is running), so of course the connection fails. ; this last bit of information may be of a low entropy, since it really shouldn't matter.

So, how can I use Perl to make XML RPC calls to an ip6 server?

For instance :

% host perso.priv.fperrin.net
perso.priv.fperrin.net has IPv6 address fd93:c8e5:9cb3::3 % cat ariactl.pl use strict; use warnings; use Frontier::Client; my $ariactl = Frontier::Client->new(url => "http://user:PaSSw0rd\@perso.priv.fperrin.net:6800/rpc"); my $v = $ariactl->call("getVersion"); print $v; % perl ariactl.pl 500 Can't connect to perso.priv.fperrin.net:6800 (connect: Connection refused) zsh: exit 61 perl ariactl.pl % cat ariactl.cmdline.py from xmlrpclib import ServerProxy aria2 = ServerProxy("http://user::6800/rpc").aria2 v = aria2.getVersion print v % python ariactl.cmdline.py {'version': '1.8.1', 'enabledFeatures': ['BitTorrent', 'GZip', 'HTTPS', 'Message Digest', 'Metalink', 'XML-RPC']}
 

Frédéric Perrin

Usenet Archive
Joined
Feb 5, 2010
Messages
9
Reaction score
0
Le Vendredi 05 à 23:45, Frédéric Perrin a écrit :
I want to talk to an XML RPC service over ip6 (the server doesn't listen over ip4). However, with the three modules I tried so far (XML::RPC, RPC::XML, Frontier::RPC::Client), it tries to do the request over ip4, even though the hostname I gave only resolve to ip6.

A (the?) solution is to « use Net::INET6Glue::INET_is_INET6 » before useing the actual XML RPC module. It worked with all the three modules I tried.

Question: why isn't this the default, in 2010?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

XML-RPC Problem? 0
WSDL/SOAP/XML-RPC HELP 4
Security on XML-RPC 1
ssl xml rpc 7
XML-RPC 1
Sample Apache XML-RPC Code 0
Setting up test for XML-RPC 4
xml-rpc: are there "middleman" servers? 3

Members online

No members online now.

Forum statistics

Threads
548,049
Messages
3,104,243
Members
248,133
Latest member
DujonT

Latest Threads

Top