SquirrelMail  
Donations
News
About
Support
Screen shots
Download
Plugins
Documentation
Sponsors
Bounties













Security Notice
Phishing campain
Version 1.4.15
Security Upgrade

The filters plugin

There are a number of optional plugins which use procmail, maildrop and other utilities to filter mail at delivery time. That is, they run in conjunction with the mail server. Some sites may not allow you to add this capability to your MTA, but you can use a standard plugin to get SquirrelMail to do this as it scans your message.

Use the "./configure" program the select "Plugins" then the simple "filters" plugin to move it from "Available Plugins" to your list of "Installed Plugins".

Login to squirrelmail and select "Options" then "Message Filters". I scan "Only unread messages" instead of all messages. Create a filter with "New". An example:

Match:    To or CC
Contains: squirrelmail-users
Move to:  list.squirrelmail-users

Add as many as you like, but be aware that this client-side filtering (SquirrelMail is an IMAP client) is slower than MTA-based delivery-time server-side filters.

Error message

WARNING! Tell your admin to set the SpamFilters_YourHop variable.

Solution (from "plugins/filters/setup.php")

/*
 * Set this to a string containing something unique to the line in the
 * header you want me to find IPs to scan the databases with.  For example,
 * All the email coming IN from the internet to my site has a line in
 * the header that looks like (all on one line):
 * Received: [from usw-sf-list1.sourceforge.net (usw-sf-fw2.sourceforge.net
 *    [216.136.171.252]) by firewall.persistence.com (SYSADMIN-antispam
 *     0.2) with
 * Since this line indicates the FIRST hop the email takes into my network,
 * I set my SpamFilters_YourHop to 'by firewall.persistence.com' but any
 * case-sensitive string will do.  You can set it to something found on
 * every line in the header (like ' ') if you want to scan all IPs in
 * the header (lots of false alarms here tho).
 */
global $SpamFilters_YourHop;
$SpamFilters_YourHop = ' ';

Example

Received: from sitemeter.com (mail.sitemeter.com [69.44.157.220])
     by mail.mailserver.com (Postfix) with ESMTP id 487A61F6151
     for <sam@wackylabs.net>; Mon, 6 Dec 2004 08:53:21 +0000 (GMT)
Received: from SM50442 ([66.132.236.185])
     by sitemeter.com (sitemeter.com [69.44.157.220])
     (MDaemon.PRO.v7.2.0.R)
     with ESMTP id md50016287249.msg
     for <sam@wackylabs.net>; Mon, 06 Dec 2004 03:49:26 -0500

In the above address header, my real mail server is "mail.mailserver.com" and hence I would set:

$SpamFilters_YourHop = 'by mail.mailserver.com';
© 1999-2010 by The SquirrelMail Project Team