On Mon, Jul 06, 2020 at 09:14:31AM +0530, Mayuresh wrote: > As per logs, for command line delivery there are multiple daemons in > picture like pickup, local and then smtp. For python smtplib there is only > smtpd. I do not know how to make python go via the same route. I'd > probably spawn mail command from python instead of using smtplib.
mail command formation might get complex with multipart attachments and so on. For now I have just identified and added local senders with privilege to generate mail to protected destinations. (Actually a program that generates those lists adds these by default.) Not a clean solution. There must be some sendmail options that make CLI and python library do different things. Would be trying to figure out. I think comparing mail headers in both cases might help.
