Here's a milter in Rust that adds List-Unsubscribe headers. It creates a URL that has encoded email-from, rcpt-to and a HMAC SHA 256 verification hash using a shared secret key, that way the web server handling the post request doesn't have to live on the same server as the milter/smtp server. It currently adds to all messages, which maybe cause some issue. Like if you use the same SMTP server for personal emails and sending out bulk, your personal emails will have list-subscribe header and this could cause personal emails to end up in "promotions" or "updates" tab in recipients gmail.. maybe i'll work out a way to keep it separated, but probably shouldn't use the same server anyhow i suppose.
What does this do? Well essentially it will put an unsubscribe link at the top of your email in clients like gmail (other mail handlers may do the same) like the image here, the blue link at the top. possibly it improves deliverability of newsletter and transactional emails, google postmaster tools complains about missing list-unsubscribe headers anyway. It does appear they amplify spam reports, like one person hitting "this is spam" can trash 10% of your emails according to what i'm seeing in the postmaster reports. so you don't want anyone clicking that ! :)
GitHub - arduent/lu-milter: lu‑milter is a lightweight milter written in Rust that automatically generates a standards‑compliant List-Unsubscribe header for outbound messages.
lu‑milter is a lightweight milter written in Rust that automatically generates a standards‑compliant List-Unsubscribe header for outbound messages. - arduent/lu-milter
