Hello. I'm using Python subprocess to send mails on a linux server. For outlook.com addresses I get the following error in /var/log/mail.log:
Oct 14 11:41:22 myhost smtpd[1846073]: f01b467faa967988 mta delivery evpid=d9b3ae9518ff979a from=<me@server> to=<some...@outlook.com> rcpt=<-> source="server.ip.address" relay="104.47.56.161 (104.47.56.161)" delay=2s result="PermFail" stat="550 5.7.1 Unfortunately, messages from [server.ip.address] weren't sent. Please contact your Internet service provider since part of their network is on our block list (S3140). You can also refer your provider to http://mail.live.com/mail/troubleshooting.aspx#errors. [CO1NAM11FT072.eop-nam11.prod.protection.outlook.com]" So my question is, is there any way to get that output rather than ssh-ing into the server and checking the log? Can opensmtpd return that output as well as logging it? Python subprocess.stdout suggests that opensmtpd does not return anything over than 0 or 1. Cheers, Simon