my $client = IO::Socket::SSL->new("xyz.com:https")
|| warn "I encountered a problem: ".IO::Socket::SSL::errst
+r();
print $client "GET /main.cfm HTTP/1.1\n";
print $client "Host: xyz.com\n";
print $client "User-Agent: low_level/1.0\n";
print $client "Accept: text/html,application/xhtml+xml,application/xml
+;q=0.9,*/*;q=0.8 \n";
print $client "Accept-Language: en-us,en;q=0.5 \n";
print $client "Accept-Encoding: gzip, deflate \n";
print $client "Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 \n";
print $client "Connection: keep-alive \n\n";
{
local $/ = undef;
my $res = <$client>;
print $res;
($cfid, $cftoken) = ($res =~ /(CFID=.+?\;).*(CFTOKEN=.+?)\;/s );
}
print "Subsequent Req. \n";
print $client "GET /login.cfm?dparm=main HTTP/1.1\n";
print $client "Host: xyz.com\n";
print $client "User-Agent: low_level/1.0\n";
print $client "Accept: text/html,application/xhtml+xml,application/xml
+;q=0.9,*/*;q=0.8 \n";
print $client "Accept-Language: en-us,en;q=0.5 \n";
print $client "Accept-Encoding: gzip, deflate \n";
print $client "Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 \n";
print $client "Connection: keep-alive \n";
print $client "Cookie: $cfid $cftoken \n\n";
print <$client>;
The script ends abruptly after the excuting the following code without any stack trace:
Net::SSLeay::ssl_write_all(blib/lib/Net/SSLeay.pm (autosplit into blib
+/lib/auto/Net/SSLeay/ssl_write_all.al):1654):
1654: $wrote = write_partial($ssl, $written, $to_write, $$da
+ta_ref);
DB<2>
[app_user@sandhost perl]$
Version Info:
Net::SSLeay - 1.30
IO::Socket::SSL - 1.44
perl verions - 5.8.8
|