問(wèn)題1:
[root@java bin]#/usr/bin/sendemail -o tls=yes -s "smtp.exmail.qq.com:465" -f "發(fā)送郵箱" -t "接收郵箱" -xu "發(fā)送郵箱" -xp "發(fā)送郵箱密碼" -u "郵件標(biāo)題" -m "郵件正文"
返回:ERROR => Timeout while reading from smtp.exmail.qq.com:465 There was no response after 60 seconds.
解決方法:將465換成587,即為/usr/bin/sendemail -o tls=yes -s "smtp.exmail.qq.com:587" -f "發(fā)送郵箱" -t "接收郵箱" -xu "發(fā)送郵箱" -xp "發(fā)送郵箱密碼" -u "郵件標(biāo)題" -m "郵件正文"
問(wèn)題2:
[root@java bin]#/usr/bin/sendemail -o tls=yes -s "smtp.exmail.qq.com:587" -f "發(fā)送郵箱" -t "接收郵箱" -xu "發(fā)送郵箱" -xp "發(fā)送郵箱密碼" -u "郵件標(biāo)題" -m "郵件正文"
返回:invalid SSL_version specified at /usr/share/perl5/vendor_perl/IO/Socket/SSL.pm line 444.
解決方法:vi /usr/bin/sendemail
第 1906 行,將 'SSLv3 TLSv1' 修改為 'SSLv23:!SSLv2'