On Wed, Jan 11, 2023 at 04:17:31PM -0800, Dan Mahoney wrote:
> Others have suggested a program that has the option to simply create a
> new mail and attach the original as mime-attachment.
Note a message which has an attached message as a body is trivial to
create, because you simply append a blank line to the new headers and
the original message, headers and all:
From: <wrapper-sender>
To: <wrapper-recipient>
Date: <whatever>
Subject: <wrapper-subject>
MIME-Version: 1.0
Content-Type: message/rfc822
<original-message headers>
<original-message-body>
So a tool to forward a wrapped mesage is exceedinly easy to create.
> I suppose what I'm looking for is a smarter version of /bin/mail that
> knows when to only forward the body portions of a mail, but my reading
> of most of the ones in things like gnu mailutils show that they're not
> smart enough to do what I want.
Even better forward the original message, with its original headers,
allowing users to view and respond to the nested original.
> > If you're lucky, "owner-" aliases will help. Otherwise, perhaps more
> > likely, you'll have to track down which particular recipient doesn't
> > want your mail.
>
> The recipient is known. Why their bounce message cited our internal
> alias as a delivered-to address instead of their own, in their reject
> message, was the problem, that exposed the original common issue of
> "maybe aliases are the wrong way to go about this", and exposed my
> other need which is also solved by an alternate forwarder.
The bounce might have quoted whatever you put in the "To:" address,
regardless of its value. The real problem is likely something else. If
you need to rewrite the "From:" address, because you're breaking DKIM
signatures or SPF, and so run into message origin authentication
barriers, then wrapping the mesage is one option. Or use a list manager
than moves "From:" to "Reply-To:", or employs similar DMARC/SPF
work-arounds.
--
Viktor.