postsrsd icon indicating copy to clipboard operation
postsrsd copied to clipboard

Add milter service for SRS sender rewriting

Open jeredfloyd opened this issue 2 years ago • 4 comments

This changeset introduces an optional milter service for SRS sender rewriting, which can run on an inet or unix socket. This makes sender rewriting a great deal more configurable as milters can be selectively run in Postfix, and so rewriting the envelope of inbound regular mail (for example) is easily avoided.

The milter is based on the template provided in the sendmail devel documentation. It only provides the SRS sender path, as processing recipient message headers is substantially more tricky and best implemented by the existing canonical(8) TCP table. (There is no problem with recipient rewriting always being attempted on mail flows.)

I'm not familiar with CMake so may have the idioms wrong, but this builds, installs, and runs successfully on Fedora 35.

jeredfloyd avatar May 04 '22 21:05 jeredfloyd

Added fixes for the CI failures.

jeredfloyd avatar May 05 '22 00:05 jeredfloyd

sigh this passes clang-format 13, but the action is 11 -- but I think I see the error. Will patch and try again...

jeredfloyd avatar May 05 '22 13:05 jeredfloyd

I believe this should pass the clang-format CI now.

jeredfloyd avatar May 06 '22 01:05 jeredfloyd

I've confirmed that this builds for EL7, EL8, and Fedora 35, 36, and rawhide; packages can be installed and tested from here: https://copr.fedorainfracloud.org/coprs/jered/postsrsd/

jeredfloyd avatar May 06 '22 12:05 jeredfloyd

@roehling any chance to land this PR?

timkgh avatar Sep 20 '22 15:09 timkgh

I have started working on a PostSRSd version 2.0, which will also include milter support. It's not functional yet, but it's getting there.

roehling avatar Sep 20 '22 16:09 roehling

I have started working on a PostSRSd version 2.0, which will also include milter support. It's not functional yet, but it's getting there.

Great news! The natural next question is the timeframe :)

timkgh avatar Sep 20 '22 16:09 timkgh

I won't make any promises, as I'm doing this in my spare time (which is not as plentiful as it used to be back in the days), but by the end of the year is not totally unrealistic. If people are willing to test-drive the new implementation in a non-production environment to find and squash bugs, I can also cut early alpha and beta releases.

roehling avatar Sep 21 '22 06:09 roehling

I'm sure there is interest in trying early versions.

timkgh avatar Sep 21 '22 15:09 timkgh

https://github.com/roehling/postsrsd/releases/tag/2.0.0a1

roehling avatar Dec 20 '22 15:12 roehling