in reply to Issue with LWP:UserAgent use Proxy

You instruct your $ua to use the proxy for https. But your URL is http :-)

Replies are listed 'Best First'.
Re^2: Issue with LWP:UserAgent use Proxy
by Drizzt (Initiate) on May 06, 2014 at 12:23 UTC

    I change the Line

    my $req = HTTP::Request->new(GET =>'http://google.de');

    to

    my $req = HTTPS::Request->new(GET=>'https://google.de');

    but it is still the same...

      unlikely story :)
      #!/usr/bin/perl -- use strict; use warnings; use LWP; my $ua = LWP::UserAgent->new; $ua->show_progress( 1 ); $ua->proxy( [ qw{ http https } ] => q{http://127.6.6.6} ); $ua->get( q{http://example.com} ); __END__ ** GET http://example.com ==> 500 Can't connect to 127.6.6.6:80 (10061 +) (2s)