Revision: 7423 http://sourceforge.net/p/ipcop/svn/7423 Author: owes Date: 2014-04-05 20:17:43 +0000 (Sat, 05 Apr 2014) Log Message: ----------- Force smtps when using port 465. Will need CA certs (work in progress) to be usable though.
Modified Paths: -------------- ipcop/trunk/lfs/sendEmail Added Paths: ----------- ipcop/trunk/src/patches/sendEmail-v1.56_smtps.patch Modified: ipcop/trunk/lfs/sendEmail =================================================================== --- ipcop/trunk/lfs/sendEmail 2014-04-05 20:14:50 UTC (rev 7422) +++ ipcop/trunk/lfs/sendEmail 2014-04-05 20:17:43 UTC (rev 7423) @@ -83,6 +83,7 @@ @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar zxf $(DIR_DL)/$(DL_FILE) cd $(DIR_APP) && patch -Np1 -i $(DIR_PATCHES)/$(THISAPP)_system-logger.patch cd $(DIR_APP) && patch -Np1 -i $(DIR_PATCHES)/$(THISAPP)_fix-ssl-version.patch + cd $(DIR_APP) && patch -Np1 -i $(DIR_PATCHES)/$(THISAPP)_smtps.patch cd $(DIR_APP) && install -m 0755 sendEmail /usr/bin Added: ipcop/trunk/src/patches/sendEmail-v1.56_smtps.patch =================================================================== --- ipcop/trunk/src/patches/sendEmail-v1.56_smtps.patch (rev 0) +++ ipcop/trunk/src/patches/sendEmail-v1.56_smtps.patch 2014-04-05 20:17:43 UTC (rev 7423) @@ -0,0 +1,26 @@ +--- a/sendEmail ++++ b/sendEmail +@@ -1865,6 +1865,23 @@ + printmsg("DEBUG => My IP address is: $conf{'ip'}", 1); + + ++# assume 465 to be smtps ++if ($conf{'port'} == "465") { ++ printmsg("DEBUG => start_SSL"); ++ # Do Net::SSLeay initialization ++ Net::SSLeay::load_error_strings(); ++ Net::SSLeay::SSLeay_add_ssl_algorithms(); ++ Net::SSLeay::randomize(); ++ ++ if (! IO::Socket::SSL->start_SSL($SERVER)) { ++ quit("ERROR => SSL start failed: ". IO::Socket::SSL::errstr(), 1); ++ } ++ ++ printmsg("DEBUG => SSL: Using cipher: %s\n", $SERVER->get_cipher (), 3); ++ printmsg("DEBUG => %s", $SERVER->dump_peer_certificate(), 3); ++} ++ ++ + + + This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ _______________________________________________ Ipcop-svn mailing list Ipcop-svn@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/ipcop-svn