Project

General

Profile

Actions

action #1986

closed

LWP::Useragent doesn't fallback to IPv4

Added by dheidler about 10 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Feature requests
Target version:
Start date:
2014-03-26
Due date:
% Done:

0%

Estimated time:
Actions #1

Updated by dheidler about 10 years ago

The problem does appear on my machine but eg. not on innoko.

The problem is LWP::UserAgent, which doesn't work on hosts with dualstack support but without ipv6 connectivity.

strace -f -econnect /tmp/r.pl 
connect(4, {sa_family=AF_LOCAL, sun_path="/var/run/nscd/socket"}, 110) = -1 ENOENT (No such file or directory)
connect(3, {sa_family=AF_INET6, sin6_port=htons(0), inet_pton(AF_INET6, "::", &sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = 0
connect(3, {sa_family=AF_UNSPEC, sa_data="\0\0\0\0\0\0\0\0\0\0\0\0\0\0"}, 16) = 0
connect(3, {sa_family=AF_INET, sin_port=htons(0), sin_addr=inet_addr("0.0.0.0")}, 16) = 0
connect(3, {sa_family=AF_LOCAL, sun_path="/var/run/nscd/socket"}, 110) = -1 ENOENT (No such file or directory)
connect(3, {sa_family=AF_INET, sin_port=htons(53), sin_addr=inet_addr("10.120.2.88")}, 16) = 0
connect(3, {sa_family=AF_INET, sin_port=htons(443), sin_addr=inet_addr("130.57.66.6")}, 16) = 0
connect(3, {sa_family=AF_INET6, sin6_port=htons(443), inet_pton(AF_INET6, "2600:806:310::100", &sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = 0
connect(3, {sa_family=AF_INET6, sin6_port=htons(443), inet_pton(AF_INET6, "2600:806:310::100", &sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = -1 EINPROGRESS (Operation now in progress)
connect(3, {sa_family=AF_INET6, sin6_port=htons(443), inet_pton(AF_INET6, "2600:806:310::100", &sin6_addr), sin6_flowinfo=0, sin6_scope_id=0}, 28) = -1 ECONNREFUSED (Connection refused)
500 Can't connect to www.opensuse.org:443 (Verbindungsaufbau abgelehnt) at /tmp/r.pl line 22.
+++ exited with 111 +++

on innoko:

strace -f -econnect /tmp/r.pl
connect(3, {sa_family=AF_LOCAL, sun_path="/var/run/nscd/socket"}, 110) = 0
connect(3, {sa_family=AF_INET, sin_port=htons(443), sin_addr=inet_addr("130.57.66.6")}, 16) = -1 EINPROGRESS (Operation now in progress)
connect(3, {sa_family=AF_INET, sin_port=htons(443), sin_addr=inet_addr("130.57.66.6")}, 16) = 0
OK
+++ exited with 0 +++

my testscript:

#!/usr/bin/perl
use strict;
use warnings;
use LWP::UserAgent;
my $user_agent = LWP::UserAgent->new;
my $request = HTTP::Request->new(GET => "https://www.opensuse.org/openid/user/");
my $response = $user_agent->request($request);
if ($response->is_success) {
print "OK\n";
} else {
die($response->status_line);
}
Actions #2

Updated by dheidler about 10 years ago

  • Subject changed from Get Net::OpenID::Consumer 1.15 working to LWP::Useragent doesn't fallback to IPv4
  • Description updated (diff)
Actions #3

Updated by ancorgs almost 10 years ago

  • Target version set to future
Actions #4

Updated by coolo over 9 years ago

  • Category set to 130
Actions #5

Updated by oholecek over 9 years ago

This again hit me (and Vladimir) when IPv6 route broke. Should I just make it to strictly use IPv4 or look for different UA to use with OpenID?

Actions #6

Updated by RBrownSUSE over 8 years ago

  • Priority changed from High to Normal
Actions #7

Updated by coolo over 7 years ago

  • Status changed from New to Closed

this can get older on a different bug tracker

Actions #8

Updated by okurz almost 6 years ago

  • Target version changed from future to future
Actions

Also available in: Atom PDF