Allow discard-and-forward for spam filters?
![](https://secure.gravatar.com/avatar/0eaf6cbffe604fc6ef41da572b970fae.jpg?s=120&d=mm&r=g)
Hello,
Because of centralized administration of mailman server used by many campus units, and other general inertia, we still use 2.1.12 (a couple of local mods; I know of one for sure for recognizing alternative email addresses).
So I am wondering if later versions of Mailman 2 have added something which seems to me to be obviously missing.
In (showing a representative, not necessarily real, URL) https://python.org/mailman/admin/mailman-users/privacy/sender you can choose to "discard" most messages and check "forward discarded messages to the moderator".
However, in https://python.org/mailman/admin/mailman-users/privacy/spam you can only Dicard or Hold. (Complete list Defer, Hold, Reject, Discard, Accept).
It would be nice if for each filter rule individually you could choose "discard and forward to moderator".
Has that actually been implemented in subsequent versions of Mailman 2, i.e. between 2.1.12 and 2.1.21 ?
I assume in Version 3 the filter capabilities have been completely redone and probably regularized.
It began to seem prudent for us to hold "slightly spammy" mail for inspection. A problem is that the majority of those would have been rejected by the sender filters anyway (though we're interested in those that wouldn't), so this has resulted in a lot of extra moderator work.
Now certainly we wouldn't want [or would appreciate the choice not] to "forward to moderator" all discards on the /spam page. And, really, the "does this fail the membership (filter) requirements" is something you'd like to be able to determine in the spam filters. (And simply discard those, perhaps forwarding if they are not too spammy). (Because really really we'd like to "hold" slightly spammy messages which meet membership requirements, but discard-and-forward the others, but discarding-and-forwarding-to-moderator all would be reasonable compromise).
I wondered too about combined expressions (and negation). Those don't look easy to do.
header_filter_rules (privacy): Filter rules to match against the
headers of a message.
Each header filter rule has two parts, a list of regular
expressions, one per line, and an action to take. Mailman matches
the message's headers against every regular expression in the rule
and if any match, the message is rejected, held, or discarded
based on the action you specify. Use Defer to temporarily disable
a rule. You can have more than one filter rule for your list. In
that case, each rule is matched in turn, with processing stopped
after the first match. Note that headers are collected from all
the attachments (except for the mailman administrivia message) and
matched against the regular expressions. With this feature, you
can effectively sort out messages with dangerous file types or
file name extensions.
Since you can always add multiple rules to achieve "or", it seems unfortunate (but past history now) that multiple expressions don't "and".
Anyway, my simple question is "did Mailman 2 sometime after 2.1.12 gain the ability to 'dicard and forward to moderator'" as an option for each spam filter rule?
(Along with the implicit suggestion that that would be a useful option). (And the longer-term suggestion for AND and negation).
Adrian Pepper
![](https://secure.gravatar.com/avatar/56f108518d7ee2544412cc80978e3182.jpg?s=120&d=mm&r=g)
On 3/30/16 5:49 AM, Adrian Pepper wrote:
No.
It is an interesting idea. The problem is that unless someone submits a patch, I'm the one that would end up doing it, and even with a patch, I'd need to audit it. I'm starting to get more involved in MM 3, and as such, have less time for MM 2.1 "nice to haves". You can always submit a request for MM 2.1 at <>.
I don't know what your mods "for recognizing alternative email addresses" are, but there is since MM 2.1.19 and equivalent_domains list attribute to, e.g., say that @mac.com, @me.com and @icloud.com are all the same for list membership purposes.
I assume in Version 3 the filter capabilities have been completely redone and probably regularized.
Not completely redone, but redone in some respects, but probably not regularized in the ways you would want.
The easiest way for me to implement this would simply be to add a "Discard and Forward" action to the other choices. Adding a Forward checkbox that would apply to any selected action is certainly more flexible, but more complicated to implement.
Yes, it does, but as you note it's history. Maybe in MM 3.
Again, No.
(Along with the implicit suggestion that that would be a useful option). (And the longer-term suggestion for AND and negation).
AND and negation probably won't happen in MM 2.1.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
![](https://secure.gravatar.com/avatar/56f108518d7ee2544412cc80978e3182.jpg?s=120&d=mm&r=g)
On 3/30/16 5:42 PM, Mark Sapiro wrote:
You can always submit a request for MM 2.1 at <>.
Sorry, I neglected to fill in the URL. It is <https://bugs.launchpad.net/mailman/+filebug>.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
![](https://secure.gravatar.com/avatar/56f108518d7ee2544412cc80978e3182.jpg?s=120&d=mm&r=g)
On 3/30/16 5:49 AM, Adrian Pepper wrote:
No.
It is an interesting idea. The problem is that unless someone submits a patch, I'm the one that would end up doing it, and even with a patch, I'd need to audit it. I'm starting to get more involved in MM 3, and as such, have less time for MM 2.1 "nice to haves". You can always submit a request for MM 2.1 at <>.
I don't know what your mods "for recognizing alternative email addresses" are, but there is since MM 2.1.19 and equivalent_domains list attribute to, e.g., say that @mac.com, @me.com and @icloud.com are all the same for list membership purposes.
I assume in Version 3 the filter capabilities have been completely redone and probably regularized.
Not completely redone, but redone in some respects, but probably not regularized in the ways you would want.
The easiest way for me to implement this would simply be to add a "Discard and Forward" action to the other choices. Adding a Forward checkbox that would apply to any selected action is certainly more flexible, but more complicated to implement.
Yes, it does, but as you note it's history. Maybe in MM 3.
Again, No.
(Along with the implicit suggestion that that would be a useful option). (And the longer-term suggestion for AND and negation).
AND and negation probably won't happen in MM 2.1.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
![](https://secure.gravatar.com/avatar/56f108518d7ee2544412cc80978e3182.jpg?s=120&d=mm&r=g)
On 3/30/16 5:42 PM, Mark Sapiro wrote:
You can always submit a request for MM 2.1 at <>.
Sorry, I neglected to fill in the URL. It is <https://bugs.launchpad.net/mailman/+filebug>.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (2)
-
Adrian Pepper
-
Mark Sapiro