Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

check-recent-requests-sent flags some emails incorrectly #8392

Open
laurentS opened this issue Sep 23, 2024 · 0 comments
Open

check-recent-requests-sent flags some emails incorrectly #8392

laurentS opened this issue Sep 23, 2024 · 0 comments

Comments

@laurentS
Copy link
Contributor

laurentS commented Sep 23, 2024

I regularly receive (for the past couple of years at least) an email from the check-recent-requests-sent script with lines like:

failed to find request sending in MTA logs for request id <some-id> <some_url_title> (check envelope from is being set to request address in Ruby, and load-mail-server-logs crontab is working)

When checking the request page, the corresponding outgoing message is marked as "Delivered".

Looking into the code, I noticed that (for postfix, which we use), the check is for dsn=2.0.0 in the logs, but some servers reply with dsn=2.6.0 instead (outlook seems to always reply 2.6.0 and never 2.0.0).

I've not been able to find a clear explanation about what 2.6.0 means, and why it replies with it instead of the usual 2.0.0. MS forums are very vague about it, but mostly seem to consider that the email was delivered, and it's now up to the outlook receiving server to deal with the message (what the leading 2 means).

But reading through RFC3463 (which describes the codes used by RFC3464) I see first:

      2.XXX.XXX   Success

         Success specifies that the DSN is reporting a positive delivery
         action.  Detail sub-codes may provide notification of
         transformations required for delivery.

and then:

      X.6.0   Other or undefined media error

         Something about the content of a message caused it to be
         considered undeliverable and the problem cannot be well
         expressed with any of the other provided detail codes.

which I concatenate as "the email was delivered, but it's undeliverable and I can't tell you why".

This code does not make sense to me. Has anyone else looked into it?

I would be tempted to modify the code in alaveteli to also accept 2.6.0, but I'd like to confirm this with others first.

Some stats: our db has 76k log lines with 2.0.0 and 5.4k lines with 2.6.0, so about 7% of our outgoing emails hit this. Of the 5.4k lines, ~90% also contain outlook.

EDIT: for what it's worth, I tested our server with https://www.mail-tester.com (got 10/10) and confirmed that everything is ok from MS's perspective via https://sendersupport.olc.protection.outlook.com/snds. So it's unlikely that this means "marked as spam".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant