Issue with latest version and SSL site

"Markus Moeller" <[email protected]> Sun, 23 Sep 2012 00:19:38 +0100
Newsgroups gmane.comp.lang.perl.modules.lwp
Message-ID <[email protected]>
Hi,

I have a problem that my perl modules are not anymore downloading a large 
file from a https site.  It worked with a previoius built, but since I 
update all modules via cpan it fails after downloading  some parts.

I use the following code:

sub http_transfer {

    my ( $url, $file  ) = @_;

    die "Need url and dest_file as params" unless @_ > 1;

    # set the method:
    $method ||= "get";

    log_and_die("I need a URL!") unless ($url);

    # skip certification verification:
    my $ua = LWP::UserAgent->new( ssl_opts => { verify_hostname => 0 });
    my $response;

    if ( $method eq "get" ) {

        my $file_dir ||= dirname($file);
        unless ( -d $file_dir ) {
            make_path $file_dir ;
        }

        # set content_file for output, and send the request:
        $response = $ua->get($url, ':content_file' => $file );

    }
    if ( $response->is_error ) {
        log_and_die( "[" . $response->status_line . "] error trying to 
$method $url.");
    }
} # end sub _http_transfer


The platform I run on is Solaris 10 and perl ,  openssl is compiled with 
SUNWspro cc.

Any idea how to debug ?  When I use truss I see my old perl modules just 
read until the end whereas the new modules for some reason get a read = 0 
somewhere at the beginning of the file download.

Thank you
Markus