Hi, I, as other people, needed to whitelist addresses that came from servers with no rdns. whitelist_from is not a good option, so I implemented whitelist_from_rcvd_ip as a plugin.
Here is the man page. Comments are welcome. -Raul Dias NAME Mail::SpamAssassin::Plugin::WhitelistRcvdIP - perform whitelist verifi- cation over IP address. SYNOPSIS loadplugin Mail::SpamAssassin::Plugin::WhitelistRcvdIP [/path/WhitelistRcvdIP.pm] whitelist_from_rcvd_ip email_address ip.ad.re.ss/mask DESCRIPTION This plugin complements whitelist_from_rcvd leting the ip address be specified instead of the revers DNS name. USER SETTINGS whitelist_from_rcvd_ip email_address ip.add.re.ss[/mask] Same as whitelist_from_rcvd but using the ip address of the remote sender instead of the reverse DNS name. Note that the ip address can be one ip, a list of ips (space sepa- rated or multiple entries), can have (or not) a mask and can be negated with !. It can be specified in the same way as trusted_networks. Please see the discussion on whitelist_from_rcvd and trusted_net- works in "Mail::SpamAssassin::Conf". Example: whitelist_from_rcvd_ip [EMAIL PROTECTED] !64.3.23.1 64.3.0.0/16 This will whitelist any email @yahoo.com that comes from 64.3.*.* but not 64.3.23.1. OBS: The entry used is the last external relay ip. So if your internal/trusted networks entries are incorrect, you might have some problems. SEE ALSO "Mail::SpamAssassin::Conf" AUTHOR Raul Dias <[EMAIL PROTECTED]>
# #uncomment the loadplugin below to be able to use the WhitelistRcvdIP plugin #please read the pod page on how to use this "$ perldoc WhitelistRcvdIP.pm" # #loadplugin Mail::SpamAssassin::Plugin::WhitelistRcvdIP WhitelistRcvdIP.pm ifplugin Mail::SpamAssassin::Plugin::WhitelistRcvdIP header USER_IN_RCVD_IP_WLIST eval:check_for_ip_whitelist_from() describe USER_IN_RCVD_IP_WLIST From: address is in the user's ip rcvd whitelist tflags USER_IN_RCVD_IP_WLIST userconf nice noautolearn score USER_IN_RCVD_IP_WLIST -30 endif
WhitelistRcvdIP.pm
Description: Perl program