SV: forwarding email with sieve of spf domains

Sebastian Nielsen sebastian at sebbe.eu
Sun Oct 25 18:28:15 EET 2020


Yes, putting the From: into Reply-To: is a good idea to ensure the reply
button in receiver´s client doesn't break.
But remember to ONLY do it when Reply-To: is not present.

To avoid removing important information from the email, like the original
sender, it can be good to always add a header like X-Original-Sender with
the original from: when rewriting in this way.

OTOH I think this type of rewriting should be done in the MTA that is
responsible for sending the email off the server, NOT in dovecot/sieve.

In exim theres already built-in support for this type of rewriting, and I
have such rewriting on all domains for which are forward-only - to avoid SPF
errors.

-----Ursprungligt meddelande-----
Från: dovecot-bounces at dovecot.org <dovecot-bounces at dovecot.org> För Marc
Roos
Skickat: den 25 oktober 2020 16:49
Till: dovecot <dovecot at dovecot.org>
Ämne: forwarding email with sieve of spf domains


Say someone has setup spf for his domain and sends an email to a user that
has in roundcube enabled the sieve forward. If the message is forwarded
without altering the message headers, this could result in a message being
blocked or not relayed, because sending hosts ip, is not in the spf of the
from: domain.

Possible solutions are:

 -  add option if enabled, it replaces the From: with that of the email
address of the sieve user. (Maybe move the original sender to the Reply-To
header? Maybe exception for 'internal' forward?)
 -  Upon processing the message, check the spf records, if they are
enforced, do the above, otherwise do nothing.


https://tools.ietf.org/html/rfc5228#section-4.2

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5715 bytes
Desc: S/MIME Cryptographic Signature
URL: <https://dovecot.org/pipermail/dovecot/attachments/20201025/8f0ec354/attachment.p7s>


More information about the dovecot mailing list