CPAN::Forum
IO-Socket-SSL - IO::SOcket::SSL using
| Posted on Mon Aug 14 18:52:34 2006 by ikorolev |
| IO::SOcket::SSL using |
|
Hello,
I am trying to run a simple test script (see at the bottom), and the module
'IO/Socket/SSL.pm' => '0.75 from /usr/local/lib/perl5/site_perl/5.6.0/IO/Socket/SSL.pm'
invokes (here is output from debugger):
IO::Socket::SSL::configure(/usr/local/lib/perl5/site_perl/5.6.0/IO/Socket/SSL.pm:153):
153: if( ! defined ($ctx_obj = SSL_Context->new($args)) ) {
SSL_Context::new(/usr/local/lib/perl5/site_perl/5.6.0/IO/Socket/SSL.pm:666)
and further tries to invoke Net::SSLeay::CTX_load_verify_locations
685: if(!($r = Net::SSLeay::CTX_load_verify_locations($ctx,
686: $ca_file,
687: $ca_path))) {
using "default" values for CA_PATH and CA_FILE. As a result, it fails with "No such file or direct
+ory" error:
Connection failed: No such file or directory at ssl_sock.pl line 8.
Can somebody please advise how to avoid this ?
Thank you,
Igor
-------------------------------------------------------------------
#!/usr/local/bin/perl -w
use IO::Socket::SSL;
# $IO::Socket::SSL::DEFAULT_CA_FILE = undef;
# $IO::Socket::SSL::DEFAULT_CA_PATH = undef;
my $client = new IO::Socket::SSL(
LocalHost => 'dc1dev04.digitalriver.com',
LocalPort => 58411,
SSL_use_cert => 0,
# Proto => 'tcp',
# Reuse => 1,
# Timeout => 1
)
|| die "Connection failed: $!";
print $client "GET / HTTP/1.0\r\n\r\n";
print <$client>;
close $client;
|
| Write a response |
(2)
]