mirror of
https://github.com/mjl-/mox.git
synced 2025-07-12 17:04:39 +03:00
bugfix: when dkim-signing submitted messages, use the domain from the "message from header" instead of "smtp mail from"
dmarc verifiers will only accept a dkim signature if the domain the message From header matches the domain of the signature (i.e. it is "aligned"). i hadn't run into this before and when testing because thunderbird sets the "smtp mail from" to the same address as a custom "message from" header. but other mail clients don't have to do that. should fix issue #22
This commit is contained in:
@ -331,8 +331,13 @@ func Drop(ID int64, toDomain string, recipient string) (int, error) {
|
||||
return n, nil
|
||||
}
|
||||
|
||||
type ReadReaderAtCloser interface {
|
||||
io.ReadCloser
|
||||
io.ReaderAt
|
||||
}
|
||||
|
||||
// OpenMessage opens a message present in the queue.
|
||||
func OpenMessage(id int64) (io.ReadCloser, error) {
|
||||
func OpenMessage(id int64) (ReadReaderAtCloser, error) {
|
||||
qm := Msg{ID: id}
|
||||
err := queueDB.Get(&qm)
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user