How to Create Mail Filter Rules For Mailing Lists?

To control which mail messages your server will deliver to Mailing Lists, use Mailman’s Spam filters interface. To access Mailman’s Spam filters interface, click Manage on cPanel’s Mailing Lists interface (Home >> Mail >> Mailing Lists).

To create a mail filter rule with the Header filters section of the Spam filters interface, perform the following steps:

1. In the Spam Filter Rule 1 text box, enter a regular expression that will match the messages to which you wish to apply an action. The following example rules use the information that SpamAssassin provides about the message:

The following rule will apply to any message that SpamAssassin scores as spam:
1
X-Spam-Status:\s+Yes

The following rule will apply to any message that SpamAssassin scores with two +:
1
X-Spam-Bar:\s*\+\+

Note:

The SpamAssassin spam score correlates to the number of plus (+) signs in the header.

The following rule will apply to messages that match individual rules from the Barracuda spam list:
1
RCVD_IN_BRBL_LASTEXT\s+RBL: RCVD_IN_BRBL_LASTEXT
Note:

SpamAssassin adds information to the header of each mail message that it reviews. You can use this information to determine which mail filter rules to use. For information about how to view email headers, read your mail client’s documentation.
2. Next to Action, select the action that you wish Mailman to perform on the messages that match the filter. The following table describes the available options:

Option
Explanation
Defer This option disables the filter rule.
Hold This option directs Mailman to hold the messages that match the filter rule, until a moderator approves it.
Reject This option directs Mailman to reject the messages that match the filter rule.
Discard This option directs Mailman to delete the messages that match the filter rule.
Accept This option directs Mailman to accept the messages that match the filter rule.
3. Click Submit Your Changes.

Legacy anti-spam filters
To create a mail filter rule with the Legacy anti-spam filters section of the Spam filters interface, perform the following steps:

In the Legacy anti-spam filters text box, enter the header information that you wish to filter.
Click Submit Your Changes.

by-

eLite Server Management

We Specialize In cPanel Server Management
Affordable 24/7 Technical Support Company

Leave a Reply