🌻 📖 Alien::LibreSSL

NAME

Alien::LibreSSL - Alien wrapper for LibreSSL (alternative to OpenSSL)

VERSION

version 0.06

SYNOPSIS

EUMM:

 use ExtUtils::MakeMaker;
 use Alien::Base::Wrapper qw( Alien::LibreSSL !export );
 
 WriteMakefile(
   ...
   CONFIGURE => {
     'Alien::Build::Wrapper' => 0,
     'Alien::LibreSSL'       => 0,
   },
   Alien::Base::Wrapper->mm_args,
 );

MB:

 use Module::Build;
 use Alien::Base::Wrapper qw( Alien::LibreSSL !export );
 
 my $build = Module::Build->new(
   ...
   configure_requires => {
     'Alien::Build::Wrapper' => 0,
     'Alien::LibreSSL'       => 0,
   },
   Alien::Base::Wrapper->mb_args,
   ...
 );
 
 $build->create_build_script;

Perl script:

 use Alien::LibreSSL;
 use Env qw( @PATH );
 
 unshift @PATH, 'Alien::LibreSSL->bin_dir;
 system 'openssl ...';

DESCRIPTION

This module provides an implementation of SSL. It will use the system SSL, if it can be found. If the system does not provide SSL, this alien will download and build LibreSSL, a drop in replacement for OpenSSL

Motivation

SSL has lots of pitfalls. SSL on Perl has all of those pitfalls plus some more. Once you get Net::SSLeay you are mostly out of the woods. Getting Net::SSLeay to install can be problematic on some platforms. My hope is that some combination of this module and Alien::OpenSSL will one day make it easier to install Net::SSLeay.

CAVEATS

None of this applies to a system install where OpenSSL or LibreSSL is already installed.

Retrieving LibreSSL or OpenSSL via the internet when you do not already have an SSL implementation introduces a bootstrapping problem. Newer versions of Alien::Build + alienfile prefer the use of curl over Net::SSLeay because on some platforms it is more reliable. Further, this Alien will try to use wget. curl and wget will only be used if they support the https protocol. If neither curl, wget are available and Net::SSLeay isn't already installed, then this Alien will refuse to install because it has no safe way of retrieving LibreSSL from the internet. You can force an insecure install via ftp or http using the ALIEN_OPENSSL_FTP environment variable below, but that is NOT recommended.

ENVIRONMENT

ALIEN_OPENSSL_FTP

Set to 1 to allow downloads via ftp or http (the default). Set to 0 to disallow insecure downloads over ftp or http.

SEE ALSO

Alien
Alien::OpenSSL

AUTHOR

Graham Ollis <plicease@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2017-2022 by Graham Ollis.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.