TLS email (GSuite/Gmail) error

nle

Member
Oct 24, 2012
194
11
18
We've moved, and I need to set up e-mail alerts via SSL (GSuite), but after following the steps, I'm getting compiling errors on mismatched OpenSSL versions.

Compiling of PERL package Net-SSLeay-1.85:
API-different OpenSSL versions compiled in (0x1000107f) vs linked (0x1000211f) at Makefile.PL line 70.
This is the corresponding lines in the Makefile.PL:
Code:
my $compiled = Net::SSLeay::OPENSSL_VERSION_NUMBER();
    my $linked = Net::SSLeay::SSLeay();
    if (($compiled ^ $linked) >= 0x00001000) {
        die sprintf("API-different OpenSSL versions compiled in (0x%08x) vs linked (0x%08x)",
            $compiled,$linked);
(I did try the note mentioning compile errror "perl Makefile.PL CCCDLFLAGS='-DOPENSSL_NO_MD2 -fPIC", but I get the same warning)

Napp-IT:
Code:
Can't locate IO/Socket/SSL.pm in @INC (you may need to install the IO::Socket::SSL module) (@INC contains: /var/web-gui/data/napp-it/CGI /usr/perl5/site_perl/5.24.1/i86pc-solaris-thread-multi-64int /usr/perl5/site_perl/5.24.1 /usr/perl5/vendor_perl/5.24.1/i86pc-solaris-thread-multi-64int /usr/perl5/vendor_perl/5.24.1 /usr/perl5/5.24.1/lib/i86pc-solaris-thread-multi-64int /usr/perl5/5.24.1/lib . /var/web-gui/data/napp-it/zfsos/_lib/illumos /var/web-gui/_my/zfsos/_lib /var/web-gui/data/napp-it/zfsos/15_Jobs and data services /var/web-gui/data/napp-it/zfsos/15_Jobs and data services/04_TLS Email) at /var/web-gui/data/napp-it/CGI/Net/SMTP/TLS.pm line 91. 
BEGIN failed--compilation aborted at /var/web-gui/data/napp-it/CGI/Net/SMTP/TLS.pm line 91. Compilation failed in require at /var/web-gui/data/napp-it/zfsos/15_Jobs and data services/04_TLS Email/09_TLS-test/action.pl line 77. 
BEGIN failed--compilation aborted at /var/web-gui/data/napp-it/zfsos/15_Jobs and data services/04_TLS Email/09_TLS-test/action.pl line 77. Compilation failed in require at admin.pl line 500.
Running OmniOS v11 r151022cj.

Not sure how to proceed next. I've done this before on another install, and it worked fine.
 

nle

Member
Oct 24, 2012
194
11
18
That's what I've been trying first. And then trying to compile them manually.

This is the output.

SSLeay works fine, but the IO::Socket::SSL fails.

Code:
pan[2]> notest install IO::Socket::SSL
Running install for module 'IO::Socket::SSL'
Checksum for /export/home/user/.cpan/sources/authors/id/S/SU/SULLR/IO-Socket-SSL-2.064.tar.gz ok
Scanning cache /export/home/user/.cpan/build for sizes
............................................................................DONE
'YAML' not installed, will not store persistent state
Argument "1.4417_001" isn't numeric in numeric ge (>=) at /usr/perl5/5.24.1/lib/CPAN/Distribution.pm line 651.
Configuring S/SU/SULLR/IO-Socket-SSL-2.064.tar.gz with Makefile.PL
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
        LC_ALL = (unset),
        LC_CTYPE = "UTF-8",
        LANG = (unset)
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
API-different OpenSSL versions compiled in (0x1000107f) vs linked (0x1000212f) at Makefile.PL line 68.
Warning: No success on command[/usr/perl5/5.24.1/bin/i386/perl Makefile.PL]
  SULLR/IO-Socket-SSL-2.064.tar.gz
  /usr/perl5/5.24.1/bin/i386/perl Makefile.PL -- NOT OK
Failed during this command:
 SULLR/IO-Socket-SSL-2.064.tar.gz             : writemakefile NO '/usr/perl5/5.24.1/bin/i386/perl Makefile.PL' returned status 65280
Running this as root btw. Locale errors are from iTerm, but shouldn't cause an issue.
 

gea

Well-Known Member
Dec 31, 2010
2,468
832
113
DE
Open-SSL is a critical issue between 151022 and 151028 where OmniOS switched from Sun SSH to Open-SSH. This switch was finally done with 151028 where all parts of Sun SSH were removed. On an updated system from 151026 to 151028 TLS stopped working and I have seen a lot of problems that I fixed with a fresh install of 151028 instead the update.

TLS installation worked for me with 151022 but it may be that any newer update (i have not tested with latest 151022) introduced a problem. As a workaround you can use the restricted Gmail server on port 25 without TLS that forwards to gmail accounts only


Restricted Gmail SMTP server
(Hope this is still working and your local internet provider must allow client smtp over port 25)

This SMTP server does not require TLS or authentication. It is restricted because emails can only be sent to other Gmail addresses or Google apps users--therefore it may only make sense for testing within an internal network that uses Gmail or Google apps. Limits apply per recipient.

The configuration information is as follows:

Host/SMTP Mail Server aspmx.l.google.com
Port 25
Connection/Use TLS if available (optional)
Authentication Open


In a few weeks there is a new 151030 LTS
If you want to use OmniOS LTS you can solve this problem together with an OmniOS update.
 
Last edited:
  • Like
Reactions: nle

nle

Member
Oct 24, 2012
194
11
18
Thanks! That worked. I have the latest packages, so something is probably broken somewhere.

I have two-factor authentication enabled and made an application password. Just put in the information, and it worked fine. It's sending to a GSuite mail, so it's no problem.