mirror of
https://github.com/mjl-/mox.git
synced 2024-12-26 16:33:47 +03:00
add Deliver-To header for delivered messages
for (experimental) rfc 9228
This commit is contained in:
parent
20ebdae8ea
commit
0fc59af9a8
1 changed files with 7 additions and 2 deletions
|
@ -2324,9 +2324,14 @@ func (c *conn) deliver(ctx context.Context, recvHdrFor func(string) string, msgW
|
|||
}
|
||||
|
||||
// ../rfc/5321:3204
|
||||
// ../rfc/5321:3300
|
||||
// Received-SPF header goes before Received. ../rfc/7208:2038
|
||||
msgPrefix := []byte("Return-Path: <" + c.mailFrom.String() + ">\r\n" + authResults.Header() + receivedSPF.Header() + recvHdrFor(rcptAcc.rcptTo.String()))
|
||||
msgPrefix := []byte(
|
||||
"Delivered-To: " + rcptAcc.rcptTo.XString(c.smtputf8) + "\r\n" + // ../rfc/9228:274
|
||||
"Return-Path: <" + c.mailFrom.String() + ">\r\n" + // ../rfc/5321:3300
|
||||
authResults.Header() +
|
||||
receivedSPF.Header() +
|
||||
recvHdrFor(rcptAcc.rcptTo.String()),
|
||||
)
|
||||
if !msgWriter.HaveHeaders {
|
||||
msgPrefix = append(msgPrefix, "\r\n"...)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue