I use Exim on a Centos distribution and have some problems with the mail sending. In order to make all the email pass the spam filters the "Return-path" and "Sender" headers have to be attached to each email.
What should I do in order to have "Return-path" and "Sender" headers added by Exim to be exactly the same as the "From" header created by my mail client ?
Thanks
Set
local_from_check
to false in the main section of your config. That will keep Exim from adding a Sender: header. If you want to be able to specify your own Sender: headers, then setlocal_sender_retain
to true.If you set
untrusted_set_sender
then your mail-client can specify the envelope sender (which on delivery is often placed into a newReturn-Path:
header) too.If your client is not specifying a sender and you want Exim to fake it up for you, then you probably want to have the Router which sends outbound mail set the errors_to option which will rewrite the SMTP envelope sender for you. That's trickier to get right, so see if the others, and client config, are enough for you.
You don't mention which mail-client you're using.