While working on this little script I ran into a bug from 2012, which was easy to fix as well.
When running the sendemail command in order to send a mail (that's what it says, right?), I got an error:
sendEmail -f firstname.lastname@example.org -t email@example.com -u Test -m 'This is a test' -s smtp.example.com:587 -xu xxx_user -xp xxx_pw -o tls=yes sendemail: invalid SSL_version specified at /usr/share/perl5/IO/Socket/SSL.pm
This is mentioned in this bug-report. And the solution is as listed quite simple:
in the mentioned file. The line number is not the one for the regex. Searching for TLSv1 matched the regex in line 1602 in my case.
After doing this little change experienced some problemsm with the Perl Module LWP::UserAgent and connecting throug HTTPS.
Error: 500 Can't connect to example.com:443
After some digging and enabling SSH debugging in perl through
use IO::Socket::SSL qw(debug3);
I found this site pointing me into the right direction:
Reinstalling the Perl Module IO::Socket::SSL via CPAN resolved the issue here:
$ CPAN install IO::Socket::SSL