Connector
view release on metacpan or search on metacpan
]
},
"prereqs" : {
"build" : {
"requires" : {
"Config::Merge" : "0",
"Config::Std" : "0",
"DBD::SQLite" : "0",
"DBI" : "0",
"ExtUtils::MakeMaker" : "6.59",
"IO::Socket::SSL" : "0",
"JSON" : "0",
"LWP::Protocol::https" : "0",
"LWP::UserAgent" : "0",
"Proc::SafeExec" : "0",
"Syntax::Keyword::Try" : "0",
"Template" : "0",
"Test::More" : "0",
"YAML" : "0"
}
},
"Test::MinimumVersion::Fast" : "0.04",
"Test::PAUSE::Permissions" : "0.07",
"Test::Pod" : "1.41",
"Test::Spellunker" : "v0.2.7"
}
},
"runtime" : {
"recommends" : {
"Config::Std" : "0",
"DBI" : "0",
"IO::Socket::SSL" : "0",
"JSON" : "0",
"LWP::Protocol::https" : "0",
"LWP::UserAgent" : "0",
"Net::LDAP" : "0",
"Proc::SafeExec" : "0",
"Template" : "0",
"Text::CSV_XS" : "0",
"YAML" : "0"
},
"requires" : {
---
abstract: 'a generic connection to a hierarchical-structured data set'
author:
- 'Scott Hardin <mrscotty@cpan.org>'
build_requires:
Config::Merge: '0'
Config::Std: '0'
DBD::SQLite: '0'
DBI: '0'
ExtUtils::MakeMaker: '6.59'
IO::Socket::SSL: '0'
JSON: '0'
LWP::Protocol::https: '0'
LWP::UserAgent: '0'
Proc::SafeExec: '0'
Syntax::Keyword::Try: '0'
Template: '0'
Test::More: '0'
YAML: '0'
configure_requires:
Module::Build::Tiny: '0.035'
file: lib/Connector/Role/SessionCache.pm
Connector::Tee:
file: lib/Connector/Tee.pm
Connector::Types:
file: lib/Connector/Types.pm
Connector::Wrapper:
file: lib/Connector/Wrapper.pm
recommends:
Config::Std: '0'
DBI: '0'
IO::Socket::SSL: '0'
JSON: '0'
LWP::Protocol::https: '0'
LWP::UserAgent: '0'
Net::LDAP: '0'
Proc::SafeExec: '0'
Template: '0'
Text::CSV_XS: '0'
YAML: '0'
requires:
Log::Log4perl: '0'
requires 'Log::Log4perl';
requires 'Moose';
requires 'perl', '5.010001';
recommends 'Config::Std';
recommends 'DBI';
recommends 'IO::Socket::SSL';
recommends 'JSON';
recommends 'LWP::Protocol::https';
recommends 'LWP::UserAgent';
recommends 'Net::LDAP';
recommends 'Proc::SafeExec';
recommends 'Template';
recommends 'Text::CSV_XS';
recommends 'YAML';
on build => sub {
requires 'Config::Merge';
requires 'Config::Std';
requires 'DBD::SQLite';
requires 'DBI';
requires 'ExtUtils::MakeMaker', '6.59';
requires 'IO::Socket::SSL';
requires 'JSON';
requires 'LWP::Protocol::https';
requires 'LWP::UserAgent';
requires 'Proc::SafeExec';
requires 'Syntax::Keyword::Try';
requires 'Template';
requires 'Test::More';
requires 'YAML';
};
lib/Connector/Proxy/SOAP/Lite.pm view on Meta::CPAN
}
if ($self->ca_certificate_file) {
$ENV{HTTPS_CA_FILE} = $self->ca_certificate_file;
}
$client->proxy($proxy);
$self->log()->trace('Using Net::SSL, EVN is' . Dumper $ENV);
} # end of Net:SSL, IO::Socket::SSL
elsif( $proxy =~ /^https:/i ) {
use IO::Socket::SSL;
$ENV{PERL_NET_HTTPS_SSL_SOCKET_CLASS} = "IO::Socket::SSL";
my $ssl_opts = {
verify_hostname => ($self->ssl_ignore_hostname ? 0 : 1)
};
if ($self->certificate_p12_file) {
die "Using pkcs12 containers is not supported by IO::Socket::SSL"
}
if ($self->certificate_key_file) {
if (!$self->certificate_file) {
die "You need to pass certificate AND key file";
}
$ssl_opts->{SSL_key_file} = $self->certificate_key_file;
$ssl_opts->{SSL_cert_file} = $self->certificate_file;
if ( $self->certificate_key_password ) {
lib/Connector/Proxy/SOAP/Lite.pm view on Meta::CPAN
if ($self->ca_certificate_path) {
$ssl_opts->{SSL_ca_path} = $self->ca_certificate_path;
}
if ($self->ca_certificate_file) {
$ssl_opts->{SSL_ca_file} = $self->ca_certificate_file;
}
# For whatever reason LWP wants the ssl_opts as ARRAYref!
$client-> proxy($proxy, ssl_opts => [%{$ssl_opts}] );
$self->log()->trace('Using IO::Socket::SSL with options ' . Dumper $ssl_opts);
} else {
# No ssl
$client->proxy($proxy);
}
if ($self->use_microsoft_dot_net_compatible_separator) {
# This modifies the seperator used in the SOAPAction Header to add
# the method to the uri. Default is # but .Net expects a slash.
$client->on_action( sub { join('/', @_) } );
}
lib/Connector/Proxy/SOAP/Lite.pm view on Meta::CPAN
=head2 SSL support
This connector supports client authentication using certificates.
=over
=item use_net_ssl
Set this to a true value to use Net::SSL as backend library (otherwise
IO::Socket::SSL is used). Be aware the Net::SSL does not check the hostname
of the server certificate so Man-in-the-Middle-Attacks might be possible.
You should use this only with a really good reason or if you need support
for PKCS12 containers.
=item ssl_ignore_hostname
Do not validate the hostname of the server certificate (only useful with
IO::Socket::SSL as Net::SSL does not check the hostname at all).
=item certificate_file
Path to a PEM encoded certificate file.
=item certificate_key_file
Path to a PEM encoded key file.
=item certificate_p12_file
lib/Connector/Role/SSLUserAgent.pm view on Meta::CPAN
if ($self->ca_certificate_path) {
$ENV{HTTPS_CA_DIR} = $self->ca_certificate_path;
}
if ($self->ca_certificate_file) {
$ENV{HTTPS_CA_FILE} = $self->ca_certificate_file;
}
$self->log()->trace('Using Net::SSL, EVN is' . Dumper $ENV);
} # end of Net:SSL, IO::Socket::SSL
elsif( $self->LOCATION() =~ /^https:/i ) {
require IO::Socket::SSL;
$ENV{PERL_NET_HTTPS_SSL_SOCKET_CLASS} = "IO::Socket::SSL";
my $ssl_opts = {
verify_hostname => ($self->ssl_ignore_hostname ? 0 : 1),
SSL_verify_mode => ($self->ssl_ignore_mode ? 0 : 1)
};
if ($self->certificate_p12_file) {
die "Using pkcs12 containers is not supported by IO::Socket::SSL"
}
if ($self->certificate_key_file) {
if (!$self->certificate_file) {
die "You need to pass certificate AND key file";
}
$ssl_opts->{SSL_key_file} = $self->certificate_key_file;
$ssl_opts->{SSL_cert_file} = $self->certificate_file;
if ( $self->certificate_key_password ) {
lib/Connector/Role/SSLUserAgent.pm view on Meta::CPAN
if ($self->ca_certificate_path) {
$ssl_opts->{SSL_ca_path} = $self->ca_certificate_path;
}
if ($self->ca_certificate_file) {
$ssl_opts->{SSL_ca_file} = $self->ca_certificate_file;
}
$ua->ssl_opts( %{$ssl_opts} );
$self->log()->trace('Using IO::Socket::SSL with options ' . Dumper $ssl_opts);
} else {
# No ssl
}
return $ua;
}
1;
__END__;
lib/Connector/Role/SSLUserAgent.pm view on Meta::CPAN
=head2 SSL support
This connector supports client authentication using certificates.
=over
=item use_net_ssl
Set this to a true value to use Net::SSL as backend library (otherwise
IO::Socket::SSL is used). Be aware the Net::SSL does not check the hostname
of the server certificate so Man-in-the-Middle-Attacks might be possible.
You should use this only with a really good reason or if you need support
for PKCS12 containers.
=item ssl_ignore_hostname
Do not validate the hostname of the server certificate (only useful with
IO::Socket::SSL as Net::SSL does not check the hostname at all).
=item certificate_file
Path to a PEM encoded certificate file.
=item certificate_key_file
Path to a PEM encoded key file.
=item certificate_p12_file
( run in 0.523 second using v1.01-cache-2.11-cpan-4d50c553e7e )