[LBBS-162] mod_smtp_mailing_lists: Add support for unsubscribe/resent headers
First, we need to implement the special list addresses list+bounce, list+owner, list+subscribe, etc. which are currently stubs, so that we can automatically process user requests.
This will involve using a database to store list members, rather than using the config file (the config file can indicate this info is stored in a database table, e.g. type=dynamic).
This will further enable RFC 8058 compliance: https://datatracker.ietf.org/doc/html/rfc8058
This requires that one-click unsubscribe be supported by emailing a special email address or making a POST request to an endpoint:
List-Unsubscribe-Post: List-Unsubscribe=One-Click
List-Unsubscribe: <http://lists.example.com/groups/leave/groupID/uniqueID>
The latter is the "email" way to handle unsubscribe; unfortunately, some big mail providers exclusively require messages include the one-click POST method or senders risk having their messages rejected. See:
Then, we could also use an external web application to use a back-end channel to the BBS to add/remove list members (BBS manager interface, anyone?). The web application would receive the one-click unsubscribe and tell the BBS to remove the application using this information.
This is useful for cases where the domain in question is already running a website that isn't on the BBS. Alternately, a subdomain could be set up for the list, and the BBS could run a minimal web application for this purpose (certainly, this would be simpler to start with).
In summary:
- need mailing lists database (table for 'lists', table for 'subscribers', table for 'posts' which is periodically pruned)
- would need to configure the base URL for List-Unsubscribe to include
- would need to have a way to pass subscribe requests to BBS (maybe in a 'superuser' capacity to subscribe another user? would be sort of reinventing LISTSERV...)
- would need to also have a way for website to pass the unsubscribe request back to the BBS (e.g. an email? if it included the token, wouldn't need to worry about spoofing)
- also ensures that DKIM signs the special List headers
Separately from the above, we should be adding these headers for list posts (and mail clients should also do this when forwarding messages):
Delivered-To: mailing list list@example.net
Resent-Date: Mon, 18 May 2026 07:09:41 -0700
Resent-From: sender@example.comComments
You must be logged in to leave a comment.