On 3/15/21 12:39 PM, Mohsen Masoudfar wrote:
Hi Mark,
Thanks again for the nice Python script. There is an issue with outlook.com. They add a '^M' (carriage Return) before msgid!! Here is part of the log that shows that. This is not in every log, though. I updated the get_log_data function (please see below), I believe it is not the smartest solution, but it seems to be working for me.
Does the script with your change produce a different result than the original?
This has nothing to do with outlook.com per se. It only has to do with the length of the log message. Further, I do not think there are actually newlines in these log messages. I think that is just an artifact of how you are viewing the log.
Mar 14 12:53:21 2021 (11701) <MN2PR20MB324587763E970CC56351F8C5B66D9@MN2PR20MB3245.namprd20.prod.outlook.com> smtp to testlist3@newlistserv.aaas.org for 1 recips, completed in 0.013000726699829102 seconds
I suspect if you do
grep namprd20.prod.outlook.com /path/to/var/logs/smtp.log
The result will be lines like
> Mar 14 12:53:21 2021 (11701) <MN2PR20MB324587763E970CC56351F8C5B66D9@MN2PR20MB3245.namprd20.prod.outlook.com> smtp to testlist3@newlistserv.aaas.org for 1 recips, completed in 0.013000726699829102 seconds
whereas if they are really split, the result would be
> <MN2PR20MB324587763E970CC56351F8C5B66D9@MN2PR20MB3245.namprd20.prod.outlook.com> smtp to testlist3@newlistserv.aaas.org for 1 recips, completed in 0.013000726699829102 seconds
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan