diff --git a/irc/accounts.go b/irc/accounts.go index 75e69e5f..9926c900 100644 --- a/irc/accounts.go +++ b/irc/accounts.go @@ -724,6 +724,7 @@ func (am *AccountManager) dispatchMailtoCallback(client *Client, account string, if config.DKIM.Domain != "" { fmt.Fprintf(&message, "Message-ID: <%s@%s>\r\n", utils.GenerateSecretKey(), config.DKIM.Domain) } + fmt.Fprintf(&message, "Date: %s\r\n", time.Now().UTC().Format(time.RFC1123Z)) fmt.Fprintf(&message, "Subject: %s\r\n", subject) message.WriteString("\r\n") // blank line: end headers, begin message body fmt.Fprintf(&message, client.t("Account: %s"), account) diff --git a/irc/email/dkim.go b/irc/email/dkim.go index c82b4b40..538ffee6 100644 --- a/irc/email/dkim.go +++ b/irc/email/dkim.go @@ -37,7 +37,7 @@ var defaultOptions = dkim.SigOptions{ Version: 1, Canonicalization: "relaxed/relaxed", Algo: "rsa-sha256", - Headers: []string{"from", "to", "subject", "message-id"}, + Headers: []string{"from", "to", "subject", "message-id", "date"}, BodyLength: 0, QueryMethods: []string{"dns/txt"}, AddSignatureTimestamp: true,