fyi, +1 on lightweight postfix spam milter alternative: 'spamassassin-milter'

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

fyi, +1 on lightweight postfix spam milter alternative: 'spamassassin-milter'

PGNet Dev
for anyone interested, 'spamassassin-milter'

        https://gitlab.com/glts/spamassassin-milter

a modern/current, rust-coded, SpamAssassin milter -- that cleanly submits msgs via spamc to spamd -- is, for me, working quite nicely with current/latest Postfix.

it appears to be lightweight, fast & stable, so far. it's free of some of the restrictions of spamass-milter; for me, notably, the limited headers passed.

the dev has been very helpful/responsive/courteous to date, and is focussed on ensuring it works with Postfix; much appreciated!

i've switched a couple of servers to using it in production; watching logs for awhile.


it currently sits at the end of my milter-chain,

  opendkim -> opendmarc -> milter-regex -> clamav-milter -> spamassassin-milter

if all continues to goe well, I'll 'jump-ship' wholesale to its use soon.


atm, it's a DIY-build, though trivial.

prereqs include

        sendmail-devel (libmilter)
        cargo
        rust

here i've

        cargo -V
                cargo 1.43.0
        rustc -V
                rustc 1.43.0

the build/install is straightforward

        git clone https://gitlab.com/glts/spamassassin-milter
        cd spamassassin-milter

note: edit milter.pc to your needs/liking

then build

        PKG_CONFIG_PATH=. cargo build

move the excutable somewhere useful

        cp -af target/debug/spamassassin-milter /usr/local/sbin/

set up a service file; mine's

        /etc/systemd/system/spamassassin-milter.service
                [Unit]
                Description=SpamAssassin Milter
                Wants  = spamd.service
                After  = syslog.target local-fs.target network-online.target spamd.service
                Before = postfix.service

                [Service]
                Type=simple
                UMask = 0117
                User=spamassassin-milter
                Group=postfix-milter
                PIDFile=/run/spamassassin-milter/spamassassin-milter.pid
                ExecStart=/usr/local/sbin/spamassassin-milter \
                 --verbose \
                 --trusted-networks '...' \
                 --max-message-size 100000000 \
                 --reject-spam \
                 --reply-code '550' \
                 --reply-status-code '5.7.1' \
                 --reply-text 'Service unavailable; REJECTED: Message Content' \
                 unix:/run/spamassassin-milter/spamassassin-milter.sock
                Restart=on-failure

                [Install]
                WantedBy=multi-user.target

make sure your chosen user:group exist & match the service file

enable/start the milter service (and of course spamd)

if interested, join in at the github project.  strength in numbers, rt?