One thing I'd like to do is move the #SRS portion of the mail stuff into #rspamd. rspamd can trivially rewrite the envelope from as a #milter. I just hardcoded bounces@server as a test, and that worked fine; so the question is how much work implementing SRS itself will be in #Lua.

This would avoid the need for #postsrsd and #postforward.

Fixed the header rewriting code in #postforward to not insert spurious newlines breaking DKIM. Now my #postfix forwarding to gmail seems to work reliably πŸ˜ƒ

https://github.com/zoni/postforward/pull/6

Rewrite headerRewriter() to not insert spurious line breaks by julian-klode Β· Pull Request #6 Β· zoni/postforward

headerRewriter() was called on a buffer filled by a tee reader as part of parsing the message headers. This buffer does not necessarily end with a newline (or in the headers; it might contain part ...