Amazon SES - Sieve Vacation MAIL FROM not working following RFC 5230

0

I am encountering an issue with Amazon SES when trying to set up Sieve vacation responses. According to RFC 5230, the SMTP MAIL FROM address should be set to <>, and the NOTIFY=NEVER parameter should be included in the RCPT TO line during the SMTP transaction if the NOTARY SMTP extension (RFC 3461) is available. Source: https://www.ietf.org/rfc/rfc5230.txt

Specifically, Section 5.1 states:

5.1.  SMTP MAIL FROM Address

   The SMTP MAIL FROM address of the message envelope SHOULD be set to
   <>.  NOTIFY=NEVER SHOULD also be set in the RCPT TO line during the
   SMTP transaction if the NOTARY SMTP extension [RFC3461] is available

However, when I attempt to implement this, I receive the following error in my mail.log:

postfix/smtp[11897]: > email-smtp.eu-west-2.amazonaws.com[35.177.173.199]:587: MAIL FROM:<> BODY=8BITMIME
postfix/smtp[11897]: smtp_stream_setup: maxtime=300 enable_deadline=0
postfix/smtp[11897]: < email-smtp.eu-west-2.amazonaws.com[35.177.173.199]:587: 501 Invalid MAIL FROM address provided

Could someone please advise on how to resolve this issue? It appears that the MAIL FROM address is not being accepted as per the specifications in RFC 5230.

Workaround, dovecot setting "sieve_vacation_send_from_recipient = yes"

J
asked 4 months ago189 views
1 Answer
3
Accepted Answer

Is there an issue with the workaround you mentioned you found already?

SHOULD doesn't imply a hard requirement or guarantee, so both requiring an address, like SES is doing, and accepting an empty address, as is the recommendation, are permitted by the RFC. I would think the reason the configuration option you found exists is because this isn't an uncommon deviation from the recommendation. For the purpose of interpreting the RFC, "should" is formally defined like this (https://www.rfc-editor.org/rfc/rfc2119):

3. SHOULD This word, or the adjective "RECOMMENDED", mean that there may exist valid reasons in particular circumstances to ignore a particular item, but the full implications must be understood and carefully weighed before choosing a different course.

The stated reason the empty address was recommended in the RFC published in 2008 was to avoid mail loops between automated senders. At the scale AWS operates email sending, they would certainly be the first to know if mail loops were an actual issue in the world of 2024.

EXPERT
Leo K
answered 4 months ago
AWS
EXPERT
reviewed 3 months ago
EXPERT
reviewed 4 months ago
profile picture
EXPERT
reviewed 4 months ago
  • Thank you for your detailed response. I discovered the workaround after I posted my query and am satisfied with it. Nonetheless, I was curious about other potential solutions, and your explanation provides a comprehensive and insightful answer. I appreciate your input.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions