#!/usr/bin/perl use strict; use warnings; use LWP::UserAgent; use MIME::Base64; use Data::Dumper; my $url='https://google.co.uk'; $ENV{'HTTP_PROXY'}="http://websense:8080"; $ENV{'HTTPS_PROXY'}="http://websense:8080"; $ENV{PERL_LWP_SSL_VERIFY_HOSTNAME}=0; $ENV{HTTP_DEBUG}=1; my $ua=LWP::UserAgent->new('env_proxy'=>1,ssl_opts=>{verify_hostname=>0}); $ua->env_proxy(); my $result=$ua->get($url); print("\n $@"); #### Can't connect to google.co.uk:443 (Bad hostname) LWP::Protocol::https::Socket: Bad hostname 'google.co.uk' at /usr/local/perl/lib/site_perl/LWP/Protocol/http.pm line 47.