Result:
found more than 618 distributions - search limited to the first 2001 files matching your query ( run in 0.642 )


Net-Async-Webservice-UPS

 view release on metacpan or  search on metacpan

lib/Net/Async/Webservice/UPS.pm  view on Meta::CPAN

    return defined $self->cache;
}


sub _build_ssl_options {
    eval "require IO::Socket::SSL; require IO::Socket::SSL::Utils; require Mozilla::CA;"
        or return {};

    my $cert = IO::Socket::SSL::Utils::PEM_string2cert(<<'PEM');
-----BEGIN CERTIFICATE-----
MIICPDCCAaUCEHC65B0Q2Sk0tjjKewPMur8wDQYJKoZIhvcNAQECBQAwXzELMAkGA1UEBhMCVVMx
FzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTcwNQYDVQQLEy5DbGFzcyAzIFB1YmxpYyBQcmltYXJ5
IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTk2MDEyOTAwMDAwMFoXDTI4MDgwMTIzNTk1OVow
XzELMAkGA1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMTcwNQYDVQQLEy5DbGFzcyAz

lib/Net/Async/Webservice/UPS.pm  view on Meta::CPAN

WM1pF+NEHJwZRDmJXNycAA9WjQKZ7aKQRUzkuxCkPfAyAw7xzvjoyVGM5mKf5p/AfbdynMk2Omuf
Tqj/ZA1k
-----END CERTIFICATE-----
PEM
    return {
        SSL_verify_mode => IO::Socket::SSL::SSL_VERIFY_PEER(),
        SSL_ca => [ $cert ],
        SSL_ca_file => Mozilla::CA::SSL_ca_file(),
    };
}

lib/Net/Async/Webservice/UPS.pm  view on Meta::CPAN

=head2 C<ssl_options>

Optional hashref, its contents will be passed to C<user_agent>'s
C<do_request> method.

If L<IO::Socket::SSL> and L<Mozilla::CA> are installed, the default
value sets full TLS validation, and makes sure that the Verisign
certificate currently (as of 2015-02-03) used by the UPS servers is
recognised (see L<UPS SSL/TLS notes>).

=head1 METHODS

 view all matches for this distribution


Net-Async-XMPP

 view release on metacpan or  search on metacpan

lib/Net/Async/XMPP/Protocol.pm  view on Meta::CPAN


=cut

use IO::Async::Resolver::DNS;
use IO::Async::SSL;
use IO::Socket::SSL qw(SSL_VERIFY_NONE);
use Socket qw(getnameinfo IPPROTO_TCP NI_NUMERICHOST NI_NUMERICSERV SOCK_STREAM);
use Protocol::XMPP::Stream;
use Future::Utils 'repeat';
use curry::weak;

 view all matches for this distribution


Net-BEEP-Lite-TLSProfile

 view release on metacpan or  search on metacpan

TLSProfile.pm  view on Meta::CPAN


=head1 DESCRIPTION

This is a TLS profile for BEEP as defined by RFC 3080 for use with the
C<Net::BEEP::Lite> module.  It can be use for both the initiator and
listener roles.  This module relies heavily on the C<IO::Socket::SSL>
module for the TLS implementation.

=cut

use Carp;
use strict;
use warnings;

use XML::LibXML;
use IO::Socket::SSL;

use Net::BEEP::Lite::Message;

use base qw(Net::BEEP::Lite::BaseProfile);

TLSProfile.pm  view on Meta::CPAN

session as its first and only argument.  For example, this might be
used to change the local profiles offered.

=item SSL_*

These are parameters that are understood by C<IO::Socket::SSL::new>.
You will probably want to use a few of them: SSL_cert_file,
SSL_key_file, and SSL_verify_mode are typical.

=back

TLSProfile.pm  view on Meta::CPAN

  my $sock = $session->_socket();
  my %ssl_args = %{$self->{_ssl_args}};
  $ssl_args{SSL_server} = $self->{_is_server} if $self->{_is_server};


  my $ssl_sock = IO::Socket::SSL->start_SSL($sock, %ssl_args);

  if ($ssl_sock) {
    # SSL negotation succeeded.
    $session->_set_socket($ssl_sock);

TLSProfile.pm  view on Meta::CPAN

    $session->_tuning_reset();

    $res = 1;
  }
  else {
    $errstr = "SSL/TLS negotiation failed: ",  &IO::Socket::SSL::errstr();
    print STDERR $errstr if $self->{debug};

    $res = undef;
  }

TLSProfile.pm  view on Meta::CPAN


=head1 SEE ALSO

=over 4

=item L<IO::Socket::SSL>

=item L<Net::BEEP::Lite>

=cut

 view all matches for this distribution


Net-BigIP

 view release on metacpan or  search on metacpan

META.json  view on Meta::CPAN

            "LWP::UserAgent" : "0"
         }
      },
      "test" : {
         "requires" : {
            "IO::Socket::SSL" : "0",
            "Test::Exception" : "0",
            "Test::More" : "0"
         }
      }
   },

 view all matches for this distribution


Net-CVE

 view release on metacpan or  search on metacpan

META.json  view on Meta::CPAN

      "runtime" : {
         "requires" : {
            "HTTP::Tiny" : "0.025",
            "Carp" : "0",
            "JSON::MaybeXS" : "1.004005",
            "IO::Socket::SSL" : "1.42",
            "Data::Dumper" : "0",
            "perl" : "5.014002",
            "List::Util" : "0"
         },
         "recommends" : {
            "Data::Peek" : "0.52",
            "HTTP::Tiny" : "0.088",
            "IO::Socket::SSL" : "2.085",
            "Data::Dumper" : "2.188"
         }
      },
      "configure" : {
         "requires" : {

 view all matches for this distribution


Net-Cisco-ACS

 view release on metacpan or  search on metacpan

lib/Net/Cisco/ACS.pm  view on Meta::CPAN

package Net::Cisco::ACS;
use strict;
use Moose;

# REST IO stuff here
use IO::Socket::SSL qw( SSL_VERIFY_NONE );
use LWP::UserAgent;
use XML::Simple;

# Generics
use MIME::Base64;

lib/Net/Cisco/ACS.pm  view on Meta::CPAN


=over 3

=item L<Moose>

=item L<IO::Socket::SSL>

=item L<LWP::UserAgent>

=item L<XML::Simple>

 view all matches for this distribution


Net-Cisco-ISE

 view release on metacpan or  search on metacpan

lib/Net/Cisco/ISE.pm  view on Meta::CPAN

package Net::Cisco::ISE;
use strict;
use Moose;

# REST IO stuff here
use IO::Socket::SSL qw( SSL_VERIFY_NONE );
use LWP::UserAgent;
use XML::Simple;

# Generics
use MIME::Base64;

lib/Net/Cisco/ISE.pm  view on Meta::CPAN


=over 3

=item L<Moose>

=item L<IO::Socket::SSL>

=item L<LWP::UserAgent>

=item L<XML::Simple>

 view all matches for this distribution


Net-Citadel

 view release on metacpan or  search on metacpan

lib/Net/Citadel/ToDo.pod  view on Meta::CPAN

Add a note in the documentation about the Net::Citadel repository and home page
at GitHub? Also include a reference to where it is available at the C<gitpan>
CPAN mirror at GitHub?

Add capability to use SSL encrypted communications with the Citadel server,
perhaps using IO::Socket::SSL?

Change to using the jame@cpan.org address for Robert James Clay instead of the
jame@rocasa.us address?

Other issues: (but uncertain what this is supposed to be about except that it

 view all matches for this distribution


Net-Clacks

 view release on metacpan or  search on metacpan

example/rawclient.pl  view on Meta::CPAN

#---AUTOPRAGMAEND---

use Term::ReadKey;
use Time::HiRes qw(sleep);
use IO::Socket::IP;
use IO::Socket::SSL;
use MIME::Base64;

my $peer = shift @ARGV;
if(!defined($peer) || $peer !~ /\:/) {
    die("Usage: rawclient.pl host:port");

example/rawclient.pl  view on Meta::CPAN

) or croak("Failed to connect to Clacks message service: $ERRNO");

binmode($socket, ':bytes');
$socket->blocking(0);

IO::Socket::SSL->start_SSL($socket,
                           SSL_verify_mode => SSL_VERIFY_NONE,
                           ) or croak("Can't use SSL: " . $SSL_ERROR);

# Auth
foreach my $initcmd (@initcommands) {

 view all matches for this distribution


Net-ClientServer

 view release on metacpan or  search on metacpan

lib/Net/ClientServer.pm  view on Meta::CPAN

    close STDOUT;
    if ( defined $fileno ) {
        open STDOUT, ">&$fileno" or die "Unable open STDOUT to socket: $!";
    }
    else {
        *STDOUT= \*{ $socket } unless $socket->isa( 'IO::Socket::SSL' );
    }
    STDOUT->autoflush( 1 );
}

# Stoled from Net::Server

lib/Net/ClientServer.pm  view on Meta::CPAN

    close STDERR;
    if ( defined $fileno ) {
        open STDERR, ">&$fileno" or die "Unable open STDERR to socket: $!";
    }
    else {
        *STDERR= \*{ $socket } unless $socket->isa( 'IO::Socket::SSL' );
    }
    STDERR->autoflush( 1 );
}

1;

 view all matches for this distribution


Net-DRI

 view release on metacpan or  search on metacpan

lib/Net/DRI/Transport/Socket.pm  view on Meta::CPAN

use strict;
use warnings;

use IO::Socket::INET;
## At least this version is needed, to have getline()
use IO::Socket::SSL 0.90;

use Net::DRI::Exception;
use Net::DRI::Util;
use Net::DRI::Data::Raw;

lib/Net/DRI/Transport/Socket.pm  view on Meta::CPAN


ssl, tcp or udp

=head2 ssl_key_file ssl_cert_file ssl_ca_file ssl_ca_path ssl_cipher_list ssl_version ssl_passwd_cb

if C<socktype> is 'ssl', all key materials, see IO::Socket::SSL documentation for corresponding options

=head2 ssl_verify

see IO::Socket::SSL documentation about verify_mode (by default 0x00 here)

=head2 ssl_verify_callback

see IO::Socket::SSL documentation about verify_callback, it gets here as first parameter the transport object
then all parameter given by IO::Socket::SSL; it is explicitely verified that the subroutine returns a true value,
and if not the connection is aborted.

=head2 remote_host remote_port

hostname (or IP address) & port number of endpoint

lib/Net/DRI/Transport/Socket.pm  view on Meta::CPAN

 Net::DRI::Exception::usererr_invalid_parameters('close_after must be an integer') if ($opts{close_after} && !Net::DRI::Util::isint($opts{close_after}));
 $t{close_after}=$opts{close_after} || 0;

 if ($t{socktype} eq 'ssl')
 {
  $IO::Socket::SSL::DEBUG=$opts{ssl_debug} if exists($opts{ssl_debug});

  my %s=(SSL_use_cert => 0);
  $s{SSL_verify_mode}=(exists($opts{ssl_verify}))? $opts{ssl_verify} : 0x00; ## by default, no authentication whatsoever
  $s{SSL_verify_callback}=sub { my $r=$opts{ssl_verify_callback}->($self,@_); Net::DRI::Exception->die(1,'transport/socket',6,'SSL certificate user verification failed, aborting connection') unless $r; 1; } if (exists $opts{ssl_verify_callback} && de...
  foreach my $s (qw/key_file cert_file ca_file ca_path version passwd_cb/)

lib/Net/DRI/Transport/Socket.pm  view on Meta::CPAN

       );
 $n{LocalAddr}=$t->{local_host} if exists($t->{local_host});

 if ($type eq 'ssl')
 {
  $sock=IO::Socket::SSL->new(%{$t->{ssl_context}},
                             %n,
                            );
 }
 if ($type eq 'tcp' || $type eq 'udp')
 {
  $sock=IO::Socket::INET->new(%n);
 }

 Net::DRI::Exception->die(1,'transport/socket',6,'Unable to setup the socket for '.$t->{remote_uri}.' with error: "'.$!.($type eq 'ssl'? '" and SSL error: "'.IO::Socket::SSL::errstr().'"' : '"')) unless defined $sock;
 $sock->autoflush(1);
 $self->sock($sock);
 $self->log_output('notice','transport',$ctx,{phase=>'opening',message=>'Successfully opened socket to '.$t->{remote_uri}});
 return;
}

 view all matches for this distribution


Net-Daemon-SSL

 view release on metacpan or  search on metacpan

lib/Net/Daemon/SSL.pm  view on Meta::CPAN

package IO::Socket::SSL::SafeAccept;

use strict;
use POSIX;
use IO::Socket::SSL;
$IO::Socket::SSL::SafeAccept::VERSION = ( split " ", '# 	$Id: SSL.pm,v 1.0 2000/06/14 10:30:56 mkul Exp $	' )[3];
@IO::Socket::SSL::SafeAccept::ISA     = qw(IO::Socket::SSL);

sub accept
{
    my $this   = shift;
    my $result = $this->SUPER::accept ( @_ );

lib/Net/Daemon/SSL.pm  view on Meta::CPAN

 {
     my $this = shift;
     my $buffer;
     $this->{socket}->print ( "vasja was here\n" );
     $this->{socket}->sysread ( $buffer, 100 ); # Attention! getline() method
                                                # do not work with IO::Socket::SSL
                                                # version 0.73
                                                # see perldoc IO::Socket::SSL
                                                # for more details
 }
 package main;
 my $daemon = new MyDaemon ( {}, \ @ARGV ); # you can use --help command line key
 $daemon || die "error create daemon instance: $!\n";
 $daemon->Bind();

=head1 DESCRIPTION

This class implements an IO::Socket::SSL functionality for Net::Daemon
class. See perldoc Net::Daemon for more information about Net::Daemon usage.

=cut

use strict;

lib/Net/Daemon/SSL.pm  view on Meta::CPAN

    'Generic Net::Daemon::SSL server 1.0 (C) Michael Kulakov 2000';
}

=head2 Options

This method add IO::Socket::SSL specific options ( SSL_use_cert,
SSL_verify_mode, SSL_key_file, SSL_cert_file, SSL_ca_path, SSL_ca_file ) to
generic Net::Daemon options. See perldoc IO::Socket::SSL for description of
this options

=cut

sub Options ($)
{
    my $this = shift;
    my $options = $this->SUPER::Options();
    my $descr =  ' - see perldoc IO::Socket::SSL for same parameter';
    $options->{SSL_use_cert}    = { 'template'    => 'SSL_use_cert',
				    'description' => '--SSL_use_cert'    . $descr };
    $options->{SSL_verify_mode} = { 'template'    => 'SSL_verify_mode=s',
				    'description' => '--SSL_verify_mode' . $descr };
    $options->{SSL_key_file}    = { 'template'    => 'SSL_key_file=s',

lib/Net/Daemon/SSL.pm  view on Meta::CPAN

    $options;
}

=head2 Bind

This method creates an IO::Socket::SSL::SafeAccept socket, stores this socket
into $this->{socket} and passes control to parent Net::Daemon::Bind. The
IO::Socket::SSL::SafeAccept is a class inherited from
IO::Socket::SSL with the only difference from parent class - the accept() method of
this class returns EINTR on *any* error. This trick is needed to "hack"
Net::Daemon::Bind functionality: if this method gets an error from accept() 
( Net::Daemon::SSL auth error, for example ) it will call Fatal() method and
die unless this is a EINTR error.

lib/Net/Daemon/SSL.pm  view on Meta::CPAN

sub Bind
{
    my $this = shift;
    unless ( $this->{socket} )
    {
	$this->{socket} = new IO::Socket::SSL::SafeAccept
	    ( LocalAddr       => $this->{localaddr},
	      LocalPort       => $this->{localport},
	      Proto           => $this->{proto}  || 'tcp',
	      Listen          => $this->{listen} || 10,
	      Reuse           => 1,

lib/Net/Daemon/SSL.pm  view on Meta::CPAN

 General Public License or the Artistic License, as specified in the
 Perl README file.

=head1 SEE ALSO

L<Net::Daemon(3)>, L<IO::Socket::SSL(3)>

=cut

__END__

 view all matches for this distribution


Net-DirectConnect

 view release on metacpan or  search on metacpan

lib/Net/DirectConnect.pm  view on Meta::CPAN

    ),
    return 1
    if !$self->{'socket'};
  #$self->log( 'dev',  'timeout to', $self->{'Timeout'});
  $self->{'socket'}->timeout( $self->{'Timeout'} ) if $self->{'Timeout'};    #timeout must be after new, ifyou want nonblocking
       #$self->log( 'dev',  'ssltry'), IO::Socket::SSL->start_SSL($self->{'socket'}) if $self->{'protocol'} eq 'adcs';
       #$self->log( 'err', "connect socket  error: $@, $! [$self->{'socket'}]" ), return 1 if !$self->{'socket'};
       #$self->{'socket'}->binmode(":encoding($self->{charset_protocol})");
       #$self->{charset_protocol} = 'utf8';
       #$self->log( 'dev', "set encoding of socket to [$self->{charset_protocol}]");
       #    binmode($self->{'socket'}, ":encoding($self->{charset_protocol})");

lib/Net/DirectConnect.pm  view on Meta::CPAN

    and !$is_local_ip->( $self->{'hostip'} );
  $self->{'M'} ||= 'A';
  #$self->log( 'info', "mode set [$self->{'M'}] ");
  $self->log( 'info', "connect to $self->{'host'}($self->{'hostip'}):$self->{'port'} [me=$self->{'myip'}] ok ", );
  #$self->log( $self, 'connected1 inited', "MT:$self->{'message_type'}", ' with' );
  #$self->log( 'dev',  'ssltry'),IO::Socket::SSL->start_SSL($self->{'socket'}) if $self->{'protocol'} eq 'adcs';
  $self->connect_aft();
}

sub reconnect {    #$self->{'reconnect'} ||= sub {
  my $self = shift;

lib/Net/DirectConnect.pm  view on Meta::CPAN


=head1 INSTALLATION

 To install this module type the following:

   cpan DBD::SQLite IO::Socket::IP IO::Socket::INET6 IO::Socket::SSL
   perl Makefile.PL && make install clean

 debian:
 apt-get install libdbd-sqlite3-perl libio-socket-ip-perl libjson-xs-perl libjson-perl libmime-base32-perl liblib-abs-perl

 view all matches for this distribution


Net-DynDNS-GoDaddy

 view release on metacpan or  search on metacpan

META.json  view on Meta::CPAN

      "runtime" : {
         "requires" : {
            "Addr::MyIP" : "0",
            "File::HomeDir" : "0",
            "HTTP::Tiny" : "0",
            "IO::Socket::SSL" : "0",
            "JSON" : "0",
            "perl" : "5.006"
         }
      },
      "test" : {

 view all matches for this distribution


Net-Dynect-REST

 view release on metacpan or  search on metacpan

META.yml  view on Meta::CPAN

build_requires:
    ExtUtils::MakeMaker:  0
requires:
    Crypt::SSLeay:        0
    HTTP::Request::Common:  5.814
    IO::Socket::SSL:      0
    JSON:                 0
    LWP::Protocol::https:  0
    LWP::UserAgent:       0
no_index:
    directory:

 view all matches for this distribution


Net-EC2-Tiny

 view release on metacpan or  search on metacpan

META.json  view on Meta::CPAN

            "ExtUtils::MakeMaker" : "6.30"
         }
      },
      "runtime" : {
         "requires" : {
            "IO::Socket::SSL" : "1.83",
            "Moo" : "1.000008",
            "Net::SSLeay" : "1.52",
            "XML::Simple" : "2.20",
            "perl" : "5.014"
         }

 view all matches for this distribution


Net-EPP-MITMProxy

 view release on metacpan or  search on metacpan

lib/Net/EPP/MITMProxy.pm  view on Meta::CPAN

package Net::EPP::MITMProxy;
# ABSTRACT: A generic EPP proxy server framework.
use IO::Socket::SSL;
use Mozilla::CA;
use Net::EPP::Protocol;
use Socket6;
use Socket;
use SUPER;

lib/Net/EPP/MITMProxy.pm  view on Meta::CPAN

    if ($self->{$OPT_KEY}->{remote_key} && $self->{$OPT_KEY}->{remote_cert}) {
        $args{SSL_key_file}     = $self->{$OPT_KEY}->{remote_key};
        $args{SSL_cert_file}    = $self->{$OPT_KEY}->{remote_cert};
    }

    my $server = IO::Socket::SSL->new(%args);

    if (!$server) {
        $self->log(0, sprintf(
            'connection to [%s]:%u failed (error=%s, SSL error=%s)',
            $self->{$OPT_KEY}->{remote_server},

 view all matches for this distribution


Net-EPP-Registry-Nominet

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

    - No changes from 0.06_03

0.06_03 2022-12-08

    - Test suite fix for releasing domains to NOMINET
    - Test suite fix connections with newer IO::Socket::SSL versions

0.06_02 2022-11-11

    - Domain check returns reason for unavailability as 3rd value

 view all matches for this distribution


Net-EPP-Server

 view release on metacpan or  search on metacpan

lib/Net/EPP/Server.pm  view on Meta::CPAN

use DateTime;
use Digest::SHA qw(sha512_hex);
use File::Path qw(make_path);
use File::Spec;
use File::Slurp qw(write_file);
use IO::Socket::SSL;
use List::Util qw(any none);
use Mozilla::CA;
use Net::EPP 0.27;
use Net::EPP::Frame;
use Net::EPP::Protocol;

 view all matches for this distribution


Net-EPP

 view release on metacpan or  search on metacpan

lib/Net/EPP/Client.pm  view on Meta::CPAN

package Net::EPP::Client;
use Carp;
use IO::Socket::IP;
use IO::Socket::SSL;
use Net::EPP::Parser;
use Net::EPP::Frame::Response;
use Net::EPP::Protocol;
use bytes;
use strict;

lib/Net/EPP/Client.pm  view on Meta::CPAN

OPTIONAL. Specifies the TCP port to connect to. This defaults to C<700>.

=item * C<ssl>

OPTIONAL. If the value of this parameter is false, then a plaintext
connection will be created. Otherwise, L<IO::Socket::SSL> will be used to
provide an encrypted connection.

=item * C<frames>

DEPRECATED. If the value of this parameter is false, then the C<request()> and

lib/Net/EPP/Client.pm  view on Meta::CPAN


	my $greeting = $epp->connect(%PARAMS);

This method establishes the TCP connection. You can use the C<%PARAMS> hash to
specify arguments that will be passed on to the constructors for
L<IO::Socket::IP> (such as a timeout) or L<IO::Socket::SSL> (such as
certificate information). Which of these modules will be used is determined by
the C<ssl> parameter that was provided when instantiating the object. See the
relevant manpage for examples.

This method will C<croak()> if connection fails, so be sure to use C<eval()> if

lib/Net/EPP/Client.pm  view on Meta::CPAN

}

sub _connect_tcp {
    my ($self, %params) = @_;

    my $class = ($self->{'ssl'} == 1 ? 'IO::Socket::SSL' : 'IO::Socket::IP');

    $self->{'connection'} = $class->new(
        'PeerAddr' => $self->{'host'},
        'PeerPort' => $self->{'port'},
        'Proto'    => 'tcp',

 view all matches for this distribution


Net-Easypost

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

0.08        2013-05-19
            Seriously. Fix rate number test.

0.07        2013-05-16
            Check carriers against a regex
            For reals, make IO::Socket::SSL 
                a dependency

0.06        2013-05-15
            Make IO::Socket::SSL a prereq
            Check rate against regex

0.05        2013-05-14
            Fix post request method due to 
                Mojo deprecation warnings

 view all matches for this distribution


Net-Eboks

 view release on metacpan or  search on metacpan

META.json  view on Meta::CPAN

            "Crypt::OpenSSL::RSA" : "0",
            "DateTime" : "0",
            "Digest::SHA" : "0",
            "Getopt::Long" : "0",
            "IO::Lambda" : "1.29",
            "IO::Socket::SSL" : "0",
            "LWP" : "0",
            "MIME::Base64" : "0",
            "MIME::Entity" : "0",
            "XML::Simple" : "0",
            "perl" : "5.010"

 view all matches for this distribution


Net-FTPSSL

 view release on metacpan or  search on metacpan

FTPSSL.pm  view on Meta::CPAN

use warnings;

# Enforce a minimum version of this module or Net::FTPSSL hangs!
# v1.08 works, v1.18 added ccc() support.
# Don't use v1.79 to v1.85 due to misleading warnings.
use IO::Socket::SSL 1.26;

use vars qw( $VERSION @EXPORT $ERRSTR );
use base ( 'Exporter', 'IO::Socket::SSL' );

# Only supports IPv4 (to also get IPv6 must use IO::Socket::IP instead. v0.20)
use IO::Socket::INET;

use Net::SSLeay::Handle;

FTPSSL.pm  view on Meta::CPAN



BEGIN {
    $VERSION = "0.42";              # The version of this module!

    my $type = "IO::Socket::SSL";
    $ipv6 = 0;                      # Assume IPv4 only ...
    $IOCLASS = "IO::Socket::INET";  # Assume IPv4 only ...
    $family_key = "Domain";         # Traditional ...
    my $msg;

    my $ioOrig = $IOCLASS;

    # Can we use IPv6 vs IPv4?  Let IO::Socket::SSL make the decision for us!
    # The logic gets real messy otherwise.
    if ( ! $type->can ("can_ipv6") ) {
       $msg = "No IPv6 support available.  You must 1st upgrade $type to support it!";

    } elsif ( $type->can_ipv6 () ) {

FTPSSL.pm  view on Meta::CPAN

     # The main purpose of this option was to allow users to specify
     # client certificates when their FTPS server requires them.
     # This hash applies to both the command & data channels.
     # Tags specified here overrided normal options if any tags
     # conflict.
     # See IO::Socket::SSL for supported options.
     %ssl_args = %{$arg->{SSL_Client_Certificate}};
     $found_ssl_args = 1;
  }

  # See IO::Socket::SSL for supported options.
  # Provides a way to directly pass needed SSL_* arguments to this module.
  # There is only one Net::FTPSSL option that starts with SSL_, so skipping it!
  for (grep { m{^SSL_} } keys %{$arg}) {
     next  if ( $_ eq "SSL_Client_Certificate" );   # The FTPSSL opt to skip!
     $ssl_args{$_} = $arg->{$_};

FTPSSL.pm  view on Meta::CPAN

  }

  # Only add if not using certificates & the caller didn't provide a value ...
  unless ( $ssl_args{SSL_use_cert} || $ssl_args{SSL_verify_mode} ) {
     # Stops the Man-In-The-Middle (MITM) security warning from start_ssl()
     # when it calls configure_SSL() in IO::Socket::SSL.
     # To plug that MITM security hole requires the use of certificates,
     # so all that's being done here is supressing the warning.  The MITM
     # security hole is still open!
     # That warning is now a fatal error in newer versions of IO::Socket::SSL.
     # warn "WARNING: Your connection is vunerable to the MITM attacks\n";
     $ssl_args{SSL_verify_mode} = Net::SSLeay::VERIFY_NONE();
  }

  # --------------------------------------------------------------------------

FTPSSL.pm  view on Meta::CPAN

  my $fixHelp      = $arg->{OverrideHELP};

  # --------------------------------------------------------------------------
  # if ( $debug && ! exists $arg->{DebugLogFile} ) {
  #   # So will write any debug comments to STDERR ...
  #   $IO::Socket::SSL::DEBUG = 3;
  # }

  # A special case used for further debugging the response!
  # This special value is undocumented in the POD on purpose!
  my $debug_extra = ($debug == 99) ? 1 : 0;

FTPSSL.pm  view on Meta::CPAN


     # ------------------------------------------------------------------------
     # The options for Reusing the Session ...
     # ------------------------------------------------------------------------
     if ( $reuseSession ) {
        $ssl_args{SSL_session_cache} = IO::Socket::SSL::Session_Cache->new (4 + $reuseSession);
        $ssl_args{SSL_session_key} = "Net-FTPSSL-${VERSION}-$$:${port}";
     }

     # _debug_print_hash (undef, "Socket call", "initialization", "?", $socket);
     # _debug_print_hash (undef, "Before start_SSL() call", "initialization", "?", \%ssl_args);

FTPSSL.pm  view on Meta::CPAN

        return _croak_or_return ($socket) unless (response ($socket) == CMD_OK);
     }

     # ------------------------------------------------------------------------
     # Now transform the clear connection into a SSL one on our end.
     # Messy since newer IO::Socket::SSL modules remove {_FTPSSL_arguments}!
     # Bug Id: 120341.
     # ------------------------------------------------------------------------
     $obj = $type->start_SSL( $socket, %ssl_args );
     unless ( $obj ) {
        unless ( exists ${*$socket}{_FTPSSL_arguments} ) {
           ${*$socket}{_FTPSSL_arguments} = \%ftpssl_args;
           _print_LOG (undef, "Restoring _FTPSSL_arguments to \$socket.\n")  if ( $debug );
        }
        return _croak_or_return ( $socket, undef,
                                  "$mode: " . IO::Socket::SSL::errstr () );
     }

     unless ( exists ${*$obj}{_FTPSSL_arguments} ) {
        ${*$obj}{_FTPSSL_arguments} = \%ftpssl_args;
        $obj->_print_LOG ("Restoring _FTPSSL_arguments to \$obj.\n")  if ( $debug );

FTPSSL.pm  view on Meta::CPAN

      # Can we use SNI?
      if ( $self->can ("can_client_sni") && $self->can_client_sni () ) {
         $ssl_opts{SSL_hostname} = $ftps_ref->{data_host};
      }

      $io = IO::Socket::SSL->start_SSL ( $ftps_ref->{data_ch}, \%ssl_opts )
               or return $self->_croak_or_return ( 0,
                                      "$mode: " . IO::Socket::SSL::errstr () );

   } elsif ( $ftps_ref->{data_prot} eq DATA_PROT_PRIVATE ) {
      $io = IO::Handle->new ();
      tie ( *$io, "Net::SSLeay::Handle", $ftps_ref->{data_ch} );

FTPSSL.pm  view on Meta::CPAN

option I<ReuseSession> or I<SSL_Client_Certificate> are also used, this option
is ignored!  By default the context is always reused on encrypted data channels
via B<SSL_reuse_ctx>.

B<SSL_*> - SSL arguments which can be applied when I<start_SSL()> is finally
called to encrypt the command channel.  See I<IO::Socket::SSL> for a list of
valid arguments.

This is an alternative to using the I<SSL_Client_Certificate> option.  But
any B<SSL_*> options provided here overrides what's provided in that hash.

FTPSSL.pm  view on Meta::CPAN

is to allow you to use client certificates when talking to your I<FTP/S> server.
Options here apply to the creation of the command channel.  And when a data
channel is needed later, it uses the B<SSL_reuse_ctx> option to reuse the
command channel's context.

See I<start_SSL()> in I<IO::Socket::SSL> for more details on this and other
options available besides those for certificates.  If an option provided via
this hash conflicts with other options we would normally use, the entries in
this hash take precedence, except for any direct B<SSL_*> options provided in
both places.

FTPSSL.pm  view on Meta::CPAN

I<fix_supported()> for more details.

This option can also be usefull when your server doesn't support the I<HELP>
command itself and you need to trigger some of the conditional logic.

B<useSSL> - This option is being depreciated in favor of L<IO::Socket::SSL>'s
B<SSL_version> option.  It's just a quick and dirty way to downgrade your
connection from B<TLS> to B<SSL> which is no longer recommended.

=back

FTPSSL.pm  view on Meta::CPAN


I<Net::FTP>

I<Net::SSLeay::Handle>

I<IO::Socket::SSL>

RFC 959 - L<http://www.rfc-editor.org/info/rfc959>

RFC 2228 - L<http://www.rfc-editor.org/info/rfc2228>

 view all matches for this distribution


Net-Fastly

 view release on metacpan or  search on metacpan

lib/Net/Fastly/Client.pm  view on Meta::CPAN

    my $res = $self->_ua->_post('/login', {}, user => $self->{user}, password => $self->{password});

    carp "DEPRECATION WARNING: Username/password authentication is deprecated and will not be available starting September 2020; please migrate to API tokens as soon as possible.";

    unless ($res->is_success) {
        die "You must have IO::Socket::SSL or Crypt::SSLeay installed in order to do SSL requests\n" if $res->code == 501 && $res->status_line =~ /Protocol scheme 'https' is not supported/;
        die "Unauthorized" unless $res->is_success;
    }
    my $content = decode_json($res->decoded_content);
    $self->{_cookie} = $res->header('set-cookie');
    return wantarray ? ($self, $content->{user}, $content->{customer}) : $self;

 view all matches for this distribution


Net-Flotum

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN


0.05  2016-05-16 20:25:33 BRT
    - added method remove on Net::Flotum::Object::CreditCard

0.04  2016-04-05 15:27:22 BRT
    - require IO::Socket::SSL

0.03  2016-04-03 02:08:03 BRT
    - use different remote_id in t/ as cpan-testers run in parallel!
    - treat undef $res on Net::Flotum::API::ExceptionHandler (new I die with $@ without trying to read ->code)

 view all matches for this distribution


Net-FreshBooks-API

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

      briefly)

0.05 2009-07-16
    - Added Crypt::SSLeay to dependencies to fix the following error:
      "501 Protocol scheme 'https' is not supported (Crypt::SSLeay or
      IO::Socket::SSL not installed)"
    - Added Path::Class to dependencies

0.04 2009-07-15
    - Fixed failing test t/007_live_test.t "Can't call method "childNodes" on an
      undefined value at /tmp/net-freshbooks-api/lib/Net/FreshBooks/API/Base.pm

 view all matches for this distribution


Net-FullAuto

 view release on metacpan or  search on metacpan

lib/Net/FullAuto/FA_Core.pm  view on Meta::CPAN

#     -l C:\strawberry\c\bin\libz.dll
#     -l C:\strawberry\c\bin\ssleay32_.dll Makefile.PL
#     -M Module::Build -M Task::Weaken -M YAML
#     -M Capture::Tiny -M ExtUtils::Depends
#     -M ExtUtils::MakeMaker -M B::Utils
#     -M Data::Dump::Streamer -M LWP -M IO::Socket::SSL
#     -M LWP::Protocol::https -M Mozilla::CA
#     -M Term::RawInput -M JSON -M Term::Menus
#     -M Win32::API -M Win32::DriveInfo -M DBD::SQLite
#     -a bin -a ChangeLog -a inc -a Module -a lib -a t
#     -a META.yml -a LICENSE -a MANIFEST -a README

 view all matches for this distribution


Net-Gemini

 view release on metacpan or  search on metacpan

lib/Net/Gemini.pm  view on Meta::CPAN

use warnings;
use Digest::SHA 'sha256_hex';
use Encode ();
use Exporter 'import';
use IO::Socket::IP;
use IO::Socket::SSL;
use Net::SSLeay;
use Parse::MIME 'parse_mime_type';

our @EXPORT_OK = qw(gemini_request);

lib/Net/Gemini.pm  view on Meta::CPAN

            PeerAddr => $obj{_host},
            PeerPort => $obj{_port},
            Proto    => 'tcp'
        ) or die $!;
        $obj{_ip} = $obj{_socket}->peerhost;
        IO::Socket::SSL->start_SSL(
            $obj{_socket},
            SSL_hostname => $obj{_host},    # SNI
            ( $param{tofu} ? ( SSL_verifycn_scheme => 'none' ) : () ),
            SSL_verify_callback => sub {
                my ( $ok, $ctx_store, $certname, $error, $cert, $depth ) = @_;

lib/Net/Gemini.pm  view on Meta::CPAN

            },
            ( exists $param{ssl} ? %{ $param{ssl} } : () ),
        ) or die $!;
        1;
    } or do {
        @obj{qw(_code _error)} = ( 0, "IO::Socket::SSL failed: $@" );
        goto BLESSING;
    };

    binmode $obj{_socket}, ':raw';

lib/Net/Gemini.pm  view on Meta::CPAN

Size of buffer to use for requests, 4096 by default. Note that a naughty
server may return data in far smaller increments than this.

=item B<ssl> => { params }

Passes the given parameters to the L<IO::Socket::SSL> constructor. These
could be used to configure e.g. the C<SSL_verify_mode> or to set a
verification callback, or to specify a custom SNI host via
C<SSL_hostname>.

C<Timeout> can be used to set a connect timeout on the socket. However,

 view all matches for this distribution


Net-Google-SafeBrowsing2

 view release on metacpan or  search on metacpan

lib/Net/Google/SafeBrowsing2.pm  view on Meta::CPAN

use Digest::HMAC_SHA1 qw(hmac_sha1 hmac_sha1_hex);
use MIME::Base64::URLSafe;
use MIME::Base64;
use String::HexConvert;
use File::Slurp;
use IO::Socket::SSL 'inet4' ;


use Exporter 'import';
our @EXPORT = qw(DATABASE_RESET MAC_ERROR MAC_KEY_ERROR INTERNAL_ERROR SERVER_ERROR NO_UPDATE NO_DATA SUCCESSFUL MALWARE PHISHING);

our $VERSION = '1.13';

BEGIN {
    IO::Socket::SSL::set_ctx_defaults(
#         verify_mode => Net::SSLeay->VERIFY_PEER(),
	SSL_verify_mode => 0,
    );
}

lib/Net/Google/SafeBrowsing2.pm  view on Meta::CPAN


=over 4

=item 1.11

Add dependency on IO::Socket::SSL.
Remove dependency on Net::IPAddress.

=item 1.10

Force IPv4 to solve bug on CentOS.

 view all matches for this distribution


Net-Google-SafeBrowsing3

 view release on metacpan or  search on metacpan

lib/Net/Google/SafeBrowsing3.pm  view on Meta::CPAN

use List::Util qw(first);
use Text::Trim;
use MIME::Base64::URLSafe;
use MIME::Base64;
use String::HexConvert;
use IO::Socket::SSL 'inet4';
use Google::ProtocolBuffers;
use Data::Dumper;

use Exporter 'import';
our @EXPORT = qw(DATABASE_RESET INTERNAL_ERROR SERVER_ERROR NO_UPDATE NO_DATA SUCCESSFUL MALWARE PHISHING UNWANTED LANDING DISTRIBUTION);


BEGIN {
    IO::Socket::SSL::set_ctx_defaults(
#         verify_mode => Net::SSLeay->VERIFY_PEER(),
			SSL_verify_mode => 0,
    );
}

 view all matches for this distribution


( run in 0.642 second using v1.01-cache-2.11-cpan-4d50c553e7e )