I’m getting a lot pushback from the MTA community that setting the bounces-to field breaks the standard conformity rules because the bounce address is supposed to come from the “mail from” field, not a custom field. In php it comes from the envelope-from field. See this wikipedia article here about “bounces”: https://en.wikipedia.org/wiki/Bounce_address
As a result of this unconventional setting in PHPlist a new email spam catching system on the internet, betterbounces.net is sending bounces to the reply-to email address and NOT the bounces-to address, thereby making it difficult to automate the blacklisting of bounces because an admin now has to comb through a multitude of bounced message (from betterbounces.net) and manually delete bounces that are not sent to the bounces-to address but rather the reply-to email.
Would love some feedback on this and for someone to look into betterbounces.net practices.
From the online Exim community of engineers:
So, to summarize:
The “From:” header is a comment, and may or may not reflect reality.
Typically it does, but not always.
The “Return-Path” is a recognized way to capture the value of the “MAIL
FROM:” command, and encode it into the headers, but it is best described
as a, “Virtual Header”.
Some other headers inserted by arbitrary third parties are not documented
in ANY RFC anywhere, and almost everyone completely ignores them.
Such is the case with, “bounces-to”.
It’s not a standard.
Almost everything will ignore it.
People who expect it to always work should be prepared for disappointment.
Feedback from betterbounces.net regarding phplist “bounces-to” header on phplist outgoing messages:
The Bounces-to header is not a standard header and as such we do not use it.
With respect to our handling of the return-path header:
RFC-2821 specifies that we, as the receiving MTA, prepend the Return-path header upon final
delivery of the message to the mailbox, and set the value to the reverse path as specified in the Mail From command
(the envelope From address). If the header already exists, the receiving MTA deletes the existing header and writes a new one with the appropriate value.
We are correct in returning the DSN to the envelope from address. We wondering if you are perhaps looking for a "Variable
My research is beginning to discover that the use of bounces-to is frowned upon by mailers and MTA’s and many companies will ignore it or worse, target the email as spam.
Phplist states in the documentation:
Setting up bounce handling
In the config.php file you can set a special email address called the “message envelope address”. The “message_envelope” address is included in the message header as the “Return-Path” address, and will be used to receive bounces. Make sure you create this email account. You can set the $message_envelope in your config.php file. Don’t forget to uncomment that line, i.e. remove the # at the start of that line.
However, RFC states that it is the Mail From value, NOT the Return-Path is supposed to be used for bounces.
Does anyone care about this here? Failure to follow RFC oftentimes results in email marked as Spam.
@pancakehollow the $message_envelope value is used for both the MAIL FROM exchange and the Bounces-to header.
phplist itself only sets the header, it uses the phpmailer package to send using smtp.