Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

w.r.t. the difference between RFC2821 MAIL From and RFC2822 FROM I'm considering having my MTA add a header specifying what was sent in the MAIL FROM portion of the envelope.

The RFC2821 header is used for receiving email bouncebacks, and is the header that is checked in SPF and some SenderID configurations.

The goal is to make it easier for diagnostics and debugging by having this low level information in the email header.

  • What is an acceptable name for this SMTP header?

  • Should this header be signed by DKIM? Is there any reason why it shouldn't be signed?

share|improve this question
up vote 2 down vote accepted

On delivery, the address specified in MAIL FROM is placed in the Return-Path: header. See RFC 2821 section 4.4:

When the delivery SMTP server makes the "final delivery" of a message, it inserts a return-path line at the beginning of the mail data. This use of return-path is required; mail systems MUST support it. The return-path line preserves the information in the from the MAIL command. Here, final delivery means the message has left the SMTP environment. Normally, this would mean it had been delivered to the destination user or an associated mail drop, but in some cases it may be further processed and transmitted by another mail system.

You can't sign this header because you don't create it; the destination SMTP server adds the header.

share|improve this answer
Thank you I was thinking I could sign it with d="", that way the MUA can tell what happened with some legitimacy. AFAIK multiple DKIM signatures are OK and won't break anything... even DMARC. What do you think? – LamonteCristo Oct 7 '12 at 15:42
I wouldn't use DKIM at all for my email, so I won't presume to tell you what to think. :) – Michael Hampton Oct 7 '12 at 15:45

Headers and envelops are not the same. They even don't correspond. So whatever you do, you can't sign the header with data outside the header (in this case the envelope). It is technically not possible and is not a question on how to do it.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.